limit elevation ETOPO1

조회 수: 8 (최근 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