MATLAB Answers

How do i expand this figure so all graphs fit perfect

조회 수: 14(최근 30일)
jason
jason 12 Nov 2014
댓글: jason 12 Nov 2014

  댓글 수: 0

로그인 to comment.

채택된 답변

Chad Greene
Chad Greene 12 Nov 2014
Instead of using subplot(2,2,1), try this
figure
axes('position',[0 .5 .5 .5])
plot(1:10,1:10,'b')
axes('position',[.5 .5 .5 .5])
plot(1:10,1:10,'r')
axes('position',[0 0 .5 .5])
plot(1:10,1:10,'k')
axes('position',[.5 0 .5 .5])
plot(1:10,1:10,'m')

  댓글 수: 3

jason
jason 12 Nov 2014
how would i implement this on my code;
this is my code:
figure(1),subplot(2,2,1),imshow(RGB);title('Test Shapes');
figure(1),subplot(2,2,2),imshow(img_wk_bw_L_total);title('Classified Shapes');
figure(1),subplot(2,2,3),imshow(RGB);title('color');
figure(1),subplot(2,2,4),imshow(img_wk_bw_L_total2);title('Area in m^2');
Chad Greene
Chad Greene 12 Nov 2014
Replace my plot lines with your imshow lines. And change your title lines to
title('my title','vert','top','backgroundcolor','white')
jason
jason 12 Nov 2014
thank you, it works perfect.

로그인 to comment.

추가 답변(1개)

Robert Cumming
Robert Cumming 12 Nov 2014
you may be interested in this FEX submission which allows for you to customise the spacing.

  댓글 수: 0

로그인 to comment.

이 질문에 답변하려면 로그인을(를) 수행하십시오.

태그


Translated by