How to change size of axis labels in MappingToolbox, as well as ColorBar axis size?
5 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Kamila Turczewski
le 27 Août 2019
Commenté : Adam Danz
le 15 Juin 2020
I have been struggling to change the size of the Latitude and Longitude values on the axis of my mapping plots in the Mapping Toolbox.
I would want to increase the size of those numbers as well as the size of the axis values on the ColorBar. I tried to use axesm(), but I keep getting an error about a Projection Map.
latlim = [25 50]; lonlim = [-105 -67];
axe = usamap(latlim, lonlim);
set(axe, 'Visible', 'off');
sheds = shaperead('usastatehi','UseGeoCoords', true, 'BoundingBox', [lonlim', latlim']);
geoshow(axe, sheds, 'FaceColor', [1 1 1])
%axesm('FontSize', 15) % This doesn't work.
scatterm(lat, long, 15, ftratio, 'filled')
caxis([0 3]);
colormap jet
colorbar
0 commentaires
Réponse acceptée
Adam Danz
le 27 Août 2019
Modifié(e) : Adam Danz
le 27 Août 2019
setm(axe, 'FontSize', 15)
4 commentaires
Benoit Espinola
le 15 Juin 2020
Modifié(e) : Adam Danz
le 15 Juin 2020
Matlab is so great that setting the fontsize using the mapping toolbox, draws the text outside the figure. Not cool. Tips on how to solve this?

Adam Danz
le 15 Juin 2020
Reduce the height of the axes. To do that you need the axis handle and then change the 4th position element. For example,
ax = gca();
ax.Position(4) = ax.Position(4)*.90; %Reduce height to 90%
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Orange 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!