Can I use the fit() function to fit an ellipse on x,y data (covers only a part of the ellipse, not equally distributed around it) ? Could you please tell me how to do this? Thank you!

1 回表示 (過去 30 日間)
Istvan
Istvan 2017 年 7 月 19 日
コメント済み: Istvan 2017 年 7 月 19 日
Can I use the fit() function to fit an ellipse on x,y data (covers only a part of the ellipse, not equally distributed around it) ? Could you please tell me how to do this?
I cannot enter the equation to fit() because the equation of an ellipse ( (x-x0)^2/(a^2) + (y-y0)^2/(b^2) = 1 ) cannot be brought to a y = f(x) form...
If I cannot do it by fit(), is there ant other simple way?
I need: the center (x0,y0), the equation and the peak value (highest y).
Thank you!
  1 件のコメント
Istvan
Istvan 2017 年 7 月 19 日
fit_ellipse() ( https://uk.mathworks.com/matlabcentral/fileexchange/3215-fit-ellipse ) fails, saying: Warning: Matrix is singular, close to singular or badly scaled. Results may be inaccurate. RCOND = NaN. > In fit_ellipse (line 155) stopped because of a warning regarding matrix inversion
... and
EllipseDirectFit ( http://uk.mathworks.com/matlabcentral/fileexchange/22684-ellipse-fit--direct-method- ) will not work, as this solution expects to have data all around the ellipse. I only have data on about 30% of it.

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeInterpolation についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by