Draw Two-Dimensional Ellipse Based on Mean and Covariance using plotly
plotly_ellipse.RdThis is an updated version of ellipse. For more technical details, please refer to ellipse.
Usage
plotly_ellipse(mu, sigma, alpha=.05, npoints=250,
draw=TRUE, cex = 3, col = "#1f77b4", lwd = 3,
title = "", title.x = 0.5, title.y = 0.95, title.size = 15,
xlab = "X", xlab.size = 15, xtick.size = 15,
ylab = "Y", ylab.size = 15, ytick.size = 15)Arguments
- mu
A 2-vector giving the mean.
- sigma
A 2x2 matrix giving the covariance matrix.
- alpha
Probability to be excluded from the ellipse. The default value is alpha = .05, which results in a 95% ellipse.
- npoints
Number of points comprising the border of the ellipse.
- draw
If TRUE, draw the ellipse.
- cex
Size of markers.
- lwd
Line width of the ellipse.
- col
Color of both markers and lines.
- title
Text of the main title.
- title.size
Size of the main title.
- title.x
Horsizontal position of the main title.
- title.y
Vertical posotion of the main title.
- xlab
Label of X-axis.
- xlab.size
Size of the lable of X-axis.
- xtick.size
Size of tick lables of X-axis.
- ylab
Label of Y-axis.
- ylab.size
Size of the lable of Y-axis.
- ytick.size
Size of tick lables of Y-axis.