Can I improve the efficiency of space use while saving my figures?
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Jaime De La Mota Sanchis
le 13 Avr 2022
Réponse apportée : Voss
le 14 Avr 2022
Hello everyone. I am currently using matlab to generate some figures. I am using the following code:
figure
subplot(3,1,1)
contourf(Y,X, stdRVTotal3D)
hold on
axesm mercator;
plot(coastlon,coastlat,'k', 'LineWidth', 1.5)
axis([-20 -10 23 32])
c2 = colorbar;
caxis([0, 2.8]);
xlabel('Longitude(^o)')
ylabel('Latitude(^o)')
title('4 RV')
subplot(3,1,2)
contourf(Y,X, stdRV3RV3D)
hold on
axesm mercator;
plot(coastlon,coastlat,'k', 'LineWidth', 1.5)
axis([-20 -10 23 32])
c2 = colorbar;
caxis([0, 2.8]);
xlabel('Longitude(^o)')
ylabel('Latitude(^o)')
title('3 RV')
subplot(3,1,3)
contourf(Y,X, stdRV2RV3D)
hold on
axesm mercator;
plot(coastlon,coastlat,'k', 'LineWidth', 1.5)
axis([-20 -10 23 32])
c2 = colorbar;
caxis([0, 2.8]);
xlabel('Longitude(^o)')
ylabel('Latitude(^o)')
title('2 RV')
sgtitle('STD wind velocity in the Y direction (m/s) nodes')
However, the resulting figure has a lot of empty space.
Can someone please give me some advice on how to get bigger subplots inside of the same figure?

Best regards.
Jaime.
0 commentaires
Réponse acceptée
Voss
le 14 Avr 2022
You can try increasing the height of the figure, e.g., by dragging the edge of it, or by setting its Position in your code.
f1 = figure('Color','g');
make_subplots();
f2 = figure('Color','g','Position',[0 0 577 900]);
make_subplots();
f2 = figure('Color','g','Position',[0 0 577 1800]);
make_subplots();
function make_subplots()
subplot(3,1,1)
axesm mercator;
subplot(3,1,2)
axesm mercator;
subplot(3,1,3)
axesm mercator;
sgtitle('STD wind velocity in the Y direction (m/s) nodes')
end
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Subplots dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!