animation of figures in sequence

12 vues (au cours des 30 derniers jours)
Alberto Acri
Alberto Acri le 24 Déc 2020
Commenté : KALYAN ACHARJYA le 24 Déc 2020
Hi! Let me explain the problem.
I have several figures inserted into a single graph using "hold on" and "hold off" and I display them in steps using the "pause" command.
I want to create an animation of these figures in sequence.
How can I do it?

Réponses (1)

KALYAN ACHARJYA
KALYAN ACHARJYA le 24 Déc 2020
Modifié(e) : KALYAN ACHARJYA le 24 Déc 2020
More
https://www.mathworks.com/help/matlab/ref/drawnow.html
  2 commentaires
Alberto Acri
Alberto Acri le 24 Déc 2020
no, that's not what I wanted. Maybe I misspoke. How can I create a gif that shows the sequence of the plotted figures ?
KALYAN ACHARJYA
KALYAN ACHARJYA le 24 Déc 2020
Example:
x=0:0.1:10;
for i=1:length(x)
y=randi(10)*log(x);
plot(x,y)
drawnow
pause(0.03);
end
Do you want to save the plot all frames as gif?

Connectez-vous pour commenter.

Catégories

En savoir plus sur Animation dans Help Center et File Exchange

Produits


Version

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by