How to average out the drifting circle?

I have X and Y coordinates of a drfting trajectory (oval). The are about 2.5 passages of the drfting trajectory (oval). I would like to obtain an averaged orbit of the trajectory.
The picture below shows the trajectory. The data coordinates are blue. I want a circle like Red one.
The data for X and Y is attached below.
Here is the code for blue circles:
load('matlab.mat')
subplot(211);
plot(Rgsm(1,:),Rgsm(2,:));
Any help is greatly appriciated. Thank you in advance!

 Respuesta aceptada

KSSV
KSSV el 15 de Jun. de 2022

0 votos

5 comentarios

KSSV
KSSV el 15 de Jun. de 2022
You need to read the coomments given in the function. Check the example shown in there.
MP
MP el 15 de Jun. de 2022
Thank you for your valuable suggestions
KSSV
KSSV el 15 de Jun. de 2022
Editada: KSSV el 15 de Jun. de 2022
load('matlab.mat')
x = Rgsm(1,:) ;
y = Rgsm(2,:) ;
plot(x,y,'.b')
hold on
ellipse_t = fit_ellipse(x,y,gcf) ;
MP
MP el 15 de Jun. de 2022
Editada: MP el 15 de Jun. de 2022
Yes, That worked. Thank you so much @KSSV
KSSV
KSSV el 15 de Jun. de 2022
Perfect...
Enjoy MATLAB..!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre 2-D and 3-D Plots en Centro de ayuda y File Exchange.

Etiquetas

Preguntada:

MP
el 15 de Jun. de 2022

Comentada:

el 15 de Jun. de 2022

Community Treasure Hunt

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

Start Hunting!

Translated by