limit elevation ETOPO1

4 次查看(过去 30 天)
Madlab
Madlab 2018-9-11
评论: Madlab 2018-9-14
For a map with ETOPO, how to limit elevation [Z] such that the plotted marker and name are not covered by the map?
Right now, my marker and name is covered by the elevation. I tried editing [Z], a 1200 x 1950 double, which is madness, and I know this is not the way to alter the elevation. Not allowed to use any additional mapping toolbox.
% Creating figure
figure
% Construct map axes for region
worldmap australia
% Returning the map projection structure from the current map axes
mstruct = gcm;
% Defining limits for lat and long - adjusting map axis
latlim = mstruct.maplatlimit;
lonlim = mstruct.maplonlimit;
% Read ETOPO file within the specified lat and long limits
% "Z" is data grid, an array of elevations
% "refvec" is the three-element referencing vector
[Z, refvec] = etopo(etopoFile,2, latlim, lonlim);
% Plotting marker on map
plotm(-37.814, 144.96332, '.k','markersize',8)
% Naming on map
textm(-37.814, 144.96332,point name,'FontSize',12)
% Displaying map data, with extracted etopo value
geoshow(Z, refvec, 'DisplayType', 'surface');
% Color the map based on the terrain elevation data, Z.
demcmap(Z, 500);

采纳的回答

Amy Haskins
Amy Haskins 2018-9-11
I would try changing the geoshow line to use 'DisplayType', 'texturemap' instead of 'surface' and moving this line before the call to plotm. This will create a 2D plot rather than a 3D surface and put your markers and text on top of it.
  1 个评论
Madlab
Madlab 2018-9-14
Thank you Amy, that worked and my markers and text displayed very nicely.

请先登录,再进行评论。

更多回答(0 个)

Community Treasure Hunt

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

Start Hunting!

Translated by