This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.


Project regular data grid on map axes


H = meshm(___)


meshm(Z,R) will display the regular data grid Z warped to the default projection graticule. R can be a referencing vector, a referencing matrix, or a geographic raster reference object.

If R is a geographic raster reference object, its RasterSize property must be consistent with size(Z).

If R is a referencing vector, it must be a 1-by-3 with elements:

[cells/degree northern_latitude_limit western_longitude_limit]

If R is a referencing matrix, it must be 3-by-2 and transform raster row and column indices to/from geographic coordinates according to:

[lon lat] = [row col 1] * R

If R is a referencing matrix, it must define a (non-rotational, non-skewed) relationship in which each column of the data grid falls along a meridian and each row falls along a parallel. The current axes must have a valid map projection definition.

meshm(Z,R,gratsize) displays a regular data grid warped to a graticule mesh defined by the 1-by-2 vector gratsize. gratsize(1) indicates the number of lines of constant latitude (parallels) in the graticule, and gratsize(2) indicates the number of lines of constant longitude (meridians).

meshm(Z,R,gratsize,alt) displays the regular surface map at the altitude specified by alt. If alt is a scalar, then the grid is drawn in the z = alt plane. If alt is a matrix, then size(alt) must equal gratsize, and the graticule mesh is drawn at the altitudes specified by alt. If the default graticule is desired, set gratsize = [].

meshm(___,param1,val1,param2,val2,...) uses optional parameter name-value pairs to control the properties of the surface object constructed by meshm. (If data is placed in the UserData property of the surface, then the projection of this object cannot be altered once displayed.)

H = meshm(___) returns the handle to the surface drawn.


korea = load('korea.mat');
Z =;
R = georasterref('RasterSize', size(Z), ...
  'Latlim', [30 45], 'Lonlim', [115 135]);
worldmap(Z, R)
meshm(Z, R)

Introduced before R2006a

Was this topic helpful?