Mapping Toolbox    
extractm

Extract vector data from geographic data structures

Syntax

Description

[lat,lon] = extractm(gstruct,object) will extract vector data from those entries in the Mapping Toolbox geographic data structure that have tags beginning with the object string. The output vectors use NaNs to separate the entries in the map structure. Matches of the tag string must be vector data (lines and patches) to be included in the output.

[lat,lon] = extractm(gstruct,objects), where objects is a character array, allows more than one object to be the basis for the search.

[lat,lon] = extractm(gstruct,objects,'exact') requires an exact match to extract data.

[lat,lon,indx] = extractm(gstruct) extracts all vector data from the input map structure.

[lat,lon,indx] = extractm(...) also returns the vector indx identifying the entries in the structure which meet the selection criteria.

mat = extractm(...) returns the vector data in a single, two-column matrix, in which the first column contains latitudes and the second column, longitudes.

Examples

Extract the District of Columbia from the low resolution U.S. vector data:

Extract the states that meet at the Four Corners and plot them:

Remarks

A Mapping Toolbox geographic data structure is a MATLAB structure that may contain line, patch, text, regular matrix map, general matrix map, and light objects.

See Also
displaym
Project data in a geographic data structure
geographic data structure
Specially formatted structure for map data
mlayers
GUI for manipulating layers of a map


  eqa2grn fill3m