필터 지우기
필터 지우기

How can I plot subplots on the same size?

조회 수: 1 (최근 30일)
Agustin
Agustin 2017년 9월 18일
Hi! I'm trying to plot a figure that can show both the interferogram and coherence of radar images and I did the following:
a = angle(Interferograms(n).Interferogram);
b = Coherence(n).Spatial;
figure;
subplot 221
pcolor(X,Y,a);
shading flat;
grid on;
axis equal;
xlim([xmin xmax]);
ylim([ymin ymax]);
set(gca,'Ydir','normal');
xlabel('x [m]');
ylabel('y [m]');
cb = colorbar;
Number = n;
title(['Interferogram ' num2str(Number)]);
subplot 222
pcolor(X,Y,b);
shading flat;
grid on;
axis equal;
xlim([xmin xmax]);
ylim([ymin ymax]);
set(gca, 'Ydir', 'normal');
xlabel('x [m]');
ylabel('y [m]');
caxis([0 1]);
axpos = get(gca, 'pos');
cb = colorbar;
set(gca,'pos',axpos);
Number = n;
title(['Coherence' num2str(Number)]);
When I plot the figure I get this result:
When I maximize the window, both plots look of the same size. How can I set the the plots to look of the same size without having to click the "maximize" tab on the top right corner?
Thank you!

답변 (0개)

카테고리

Help CenterFile Exchange에서 2-D and 3-D Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by