plotting moving data points

2 vues (au cours des 30 derniers jours)
mamdouh aljoud
mamdouh aljoud le 25 Jan 2019
I'm trying to plot a skeleton model using the coordinates of the joints.
I extracted the x,y, and z coordinates and saved them in 3 matrices.
I'm trying to plot the first row of each column then have a small pause and plot the next row of each matrix.
each row of the matrices correspond to the x,y, and z coordinates of the joints and together they make a frame.
  1 commentaire
Adam
Adam le 25 Jan 2019
Which part of it is causing a problem.
doc plot3
should help with this.
Though you should use the syntax that returns the handle the first time you plot and then only update the 'XData' and 'YData' on future updates to concatenate the new points, otherwise it will be slow updating.

Connectez-vous pour commenter.

Réponses (1)

Shuqiao Xie
Shuqiao Xie le 19 Fév 2019
data = randn(10, 3)
hold on
for ii = 1: length(data)
scatter3(data(ii,1),data(ii,2),data(ii,3))
pause(1)
end

Catégories

En savoir plus sur Line Plots dans Help Center et File Exchange

Produits


Version

R2017b

Community Treasure Hunt

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

Start Hunting!

Translated by