How to copy figure settings using the drop down menus in Figure?

I have carefully edited a complex figure using the drop down menu in the Figure panel, Edit/Figure Properties and Edit/Axes Properties:
How can I use the Edit dropdown menu now to Save these settings and apply them to other figures? The instructions on the relevant Mathworks webpage (https://www.mathworks.com/help/matlab/creating_plots/customize-figure-before-saving.html#bupekdj-5) didn't work for me. Has anyone used the "export" and "save" functions on one figure and got them to export and apply to another figure?
Any help would be appreciated!

 Accepted Answer

File > Generate Code
That should do the trick for you!

3 Comments

Thanks, Michael! I'm a real novice, though, and I don't know what to do next. As you suggested, I used the pull down menu under File > generate code. I got the small dialog box indicating that something was happening, and then after a few moments, 956 lines appeared in my MatLab editor, starting with "function createfigure(ZData1, YData1, XData1, CData1, ZData2, ...
How do I use this on another figure? What do I do next to apply all those settings? (I was hoping to use the drop down menus in Figure instead of lines of script in MatLab, if possible).
I tried working with the Matlab code...too complicated for me. Is there any way to use the pulldown menu in Figure>File>Export Settings to clone the figure settings?
OK, I finally resolved the problem. I was trying to clone a ribbon plot that had >150 "ribbons" (X Y Z data) and thus was getting hundreds of comment lines and instructions on how to handle each separate "ribbon". By scrolling to the end, I found the key lines of the script:
set(axes, yada yada yada...)
and was able to copy/paste that on to my original script to get what I needed.

Sign in to comment.

More Answers (0)

Categories

Find more on Creating, Deleting, and Querying Graphics Objects in Help Center and File Exchange

Asked:

on 3 Aug 2017

Commented:

on 4 Aug 2017

Community Treasure Hunt

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

Start Hunting!