How to actually use export_fig?
246 ビュー (過去 30 日間)
How does the export_fig function work? I always get the hint to use the File Exchange and this function if I want to get high resolution pictures from my plots, but there is not a single word on how to actually use it. So everyone talks about it like you already know everything about it :( I am quite new to matlab. Do I just unzip it and copy all files in my directory of my script and then? Do I need to change something? Can someone help me with this or at least give me a link to a README that explains on how to use such functions? Thank you
Walter Roberson 2015 年 11 月 2 日
"Usage examples and tips can be found in the README section at: https://github.com/altmany/export_fig/blob/master/README.md"
To use it, go to the link in the file exchange and click on the Download link. Save the .zip file somewhere. Unzip the .zip into a separate directory in a convenient location. Then go into MATLAB and use the command
and add the directory to the MATLAB path.
After that, you call it like any function that can be used in command or function mode.
その他の回答 (1 件)
James Richard 2019 年 10 月 20 日
編集済み: James Richard 2019 年 10 月 20 日
The organized ways I think is to use the built-in Add-On Explorer itself.
- In MATLAB, open Preferences
- Navigate to MATLAB>Add-Ons
- Choose any directory that you would like it. It's one directory for all add-ons.
- Click OK
- Now, open Add-On Explorer
- Search "export_fig", then open it
- Click "Add from GitHub"
- It will ask you to sign in first, if you haven't.
- Then click OK
Don't forget to install Ghostscript and pdftops (part of the Xpdf command line tools) if you haven't.
And you're done.
Quote from https://github.com/altmany/export_fig
Locating Ghostscript/pdftops - You may find a dialogue box appears when using export_fig, asking you to locate either Ghostscript or pdftops (part of the Xpdf package). These are separate applications which export_fig requires to perform certain functions. If such a dialogue appears it is because export_fig can't find the application automatically. This is because you either haven't installed it, or it isn't in the normal place. Make sure you install the applications correctly first. They can be downloaded from the following places:
If you choose to install them in a non-default location then point export_fig to this location using the dialogue box.