www.gusucode.com > map 案例源码 matlab代码程序 > map/CreateSimpleMapsUsingWorldmapExample.m
%% Create Simple Maps Using worldmap % This example shows how to create simple maps using the |worldmap| % function. The example uses sample data sets included in the % |matlabroot/toolbox/map/mapdata| folder. %% % Set up the map frame, letting the |worldmap| function pick the % projection. This example creates a map of South America. % Copyright 2015 The MathWorks, Inc. figure worldmap 'south america' axis off %% % Determine which map projection the |worldmap| function used by looking at % the value of the |MapProjection| property of the map axes. The value % |eqdconic| stands for Equidistant Conic projection getm(gca,'MapProjection') %% % Use the |geoshow| function to import data for land areas, major rivers, % and major cities from shapefiles and display it using color you specify. geoshow('landareas.shp','FaceColor',[0.5 0.7 0.5]) geoshow('worldrivers.shp','Color', 'blue') geoshow('worldcities.shp','Marker','.','Color','red')