Hey i want to take a plot as an image via matlab.It's about my project report and i don't know how to do it.
Thank you !!
Best Answer
The easiest way is to do it directly from theplot GUI itself. Click the image of the floppy disk in the upper left corner of the GUI, choose a name and the appropriate format (I prefer.png), and save it to the directory of your choice. The advantage of this is that if you have a 3D plot and you want to rotate it, the saved image saves the rotation as well.
If you want to adjust it later (rotation or other calculations), save it as a.fig file. You can later open it in MATLAB using theopenfig function.
Don't save them as .fig files. Use imwrite() to save them as .PNG files. Otherwise you'll have to read in the figures with openfig() and then use getimage(), which is not as direct, plus .fig files are not readable by standard functions such as Photoshop or whatever.
Best Answer