# coordinates given by a suitable data frame
me <- getMinEllipse(DFsavage, tol=0.001)
plot(point.y ~ point.x, data=DFsavage, pch=16, asp=1)
drawEllipse(me, fg='blue')
# coordinates given by a matrix
if (FALSE) {
xy <- matrix(round(rnorm(20, 100, 15), 2), ncol=2)
getMinEllipse(xy, tol=0.001)
}
Run the code above in your browser using DataLab