Handling multi figures.

조회 수: 4 (최근 30일)
Junaid
Junaid 2011년 11월 30일
I have saved three figures in my system.
Figure1.fig, Figure2.fig, and Figure3.fig.
Now I want to load this figures and also want to use merge these three figure into one. Such that
subplot(1,3,1), figure1;
subplot(1,3,2), figure2;
subplot(1,3,3), figure3;
is it possible ? I know nothing is impossible but How can I do it :)

답변 (1개)

Daniel Shub
Daniel Shub 2011년 11월 30일
Assuming that each figure has only a single axis and figureN refers to the handle of the figure, you could do something like
figure1 = figure;
plot(1:10);
or
figure1 = openfig('Figure1.fig', 'new', 'invisible');
hfig = figure;
hax = subplot(1,3,1);
pos = get(hax, 'Position');
delete(hax);
hax = copyobj(get(figure1, 'children'), hfig);
set(hax, 'Position', pos);
  댓글 수: 2
Junaid
Junaid 2011년 11월 30일
Dear Daniel, thanks for reply..
As I told that I have figures in file, file format is *.fig.
I have to load from files. All figures contains different curves of time plotting.... in that secnario How can I load figures from system, in command line, and display them as one subplot(1,3,1:3)...
Titus Edelhofer
Titus Edelhofer 2011년 11월 30일
h = openfig('Figure1.fig', 'new', 'invisble');
Otherwise proceed as Daniel suggested ...

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Subplots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by