Merge two saved figures in a single figure
15 views (last 30 days)
I am struggling to merge two saves matlab figures into a single figure.
This is how the code looks like:
f1 = open('Matlab_figure_1.fig');
f2 = open('matlab_figure_2.fig');
I would need to have final figure that contains the data from f1 and f2.
Thank you for the help!
Jan on 6 Sep 2021
Edited: Jan on 6 Sep 2021
The problem cannot be solved. "Figures" can contain a toolbar, a menubar, GUI elements like buttons and popup menus. If the 2 figures contain several axes objects, you might want to show them at the original positions with a partial transparency, of you migh want to move them side by side, e.g. by subplot or tiledlayout.
There is no unique way to merge figures in general. It depends ciritically on what is contained in the figure and how you want to display the contents. For some inputs a merging is a hard challenge, e.g. if the figures use different colormaps or are drawn by different renderers.
Please elaborate the question by editing it. Append screen shots and fig files and a small scetch or exakt description of how the output should look like.