Vector map variables and data grid variables are often used or displayed together. For example, continental coastlines in vector form might be displayed with a grid of temperature data to make the latter more useful. When several map variables are used together, regardless of type, they can be referred to as a single map. To do this, of course, the different data sets must use the same coordinate system (i.e., geographic coordinates on the same ellipsoid or an identical map projection).
This example shows how to combine raster data and vector data on the same map using the
First, load elevation raster data and a geographic cells reference object. Get the coordinates of coastlines as vectors.
load topo60c load coastlines
Create a map axes object that uses the Robinson projection. Then, display the raster and apply a colormap appropriate for elevation data.
axesm robinson geoshow(topo60c,topo60cR,'DisplayType','texturemap') demcmap(topo60c)
Display the vectors in red on top of the elevation map.