Saving a file in a folder

2 vues (au cours des 30 derniers jours)
SEVAL DONERTAS
SEVAL DONERTAS le 20 Fév 2019
Commenté : SEVAL DONERTAS le 22 Fév 2019
Hi;
How can I save a file in a folder with a .FIG and .PNG extension in Matlab?
Actually I want to save the file in a folder by writing a Matlab code.
Regards,

Réponses (2)

MD RAQUIBUZZAMAN
MD RAQUIBUZZAMAN le 20 Fév 2019
f=plot(x,y);
saveas(f,'name.fig')
or you can directly use
savefig('name.fig')
  1 commentaire
SEVAL DONERTAS
SEVAL DONERTAS le 20 Fév 2019
Hi,
Thank you very much..
When I use this script; the file is saved. But axes labels, title and legend are disappeared. I am attaching my code and a txt file. What can be the problem?
Regards,

Connectez-vous pour commenter.


MD RAQUIBUZZAMAN
MD RAQUIBUZZAMAN le 20 Fév 2019
when you open the saved file, you need to use 'openfig' or open name.fig. It will load all the text and the legends.
  1 commentaire
SEVAL DONERTAS
SEVAL DONERTAS le 22 Fév 2019
Hi,
I have tried but I could not execute correctly.. Could you please write the code a bit more clearly?

Connectez-vous pour commenter.

Catégories

En savoir plus sur Printing and Saving dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by