Main Content

maptrim

(Removed) Interactively trim vector data on axesm-based map and convert to raster format

The maptrim function has been removed. Use the geocrop or geoclip function instead.

Syntax

maptrim(lat,lon,LineSpec)
maptrim(datagrid,refvec)
maptrim(datagrid,refvec,PropertyName,PropertyValue)

Description

maptrim(lat,lon) displays the supplied map data in a new figure window and allows a region of the map to be selected and saved in the workspace. lat and lon must be vector map data. The output can be line, patch, or regular surface (matrix) data. If patch map output is selected, the inputs lat and lon must originally be patch map data.

maptrim(lat,lon,LineSpec) displays the supplied map using the specified line style, marker, and color.

maptrim(datagrid,refvec) displays data grid data in a new figure window and allows a subset of this map to be selected and saved. The output is regular surface data.

maptrim(datagrid,refvec,PropertyName,PropertyValue) displays the data grid using the surface properties provided. The object Tag, EdgeColor, and UserData properties cannot be set.

Controls

Figure window containing map data and a Customize menu

The maptrim tool displays the supplied map data in a new figure window and activates a Customize menu for that figure. The Customize menu has three menu options: Zoom On/Off, Limits, and Save As.

The Zoom On/Off menu toggles interactive zoom on and off.

The Limits menu option activates the Enter Map Limits dialog box, which is used to enter the latitude and longitude limits of the desired map subset. These entries are two-element vectors, enclosed in brackets. Pressing the OK button zooms in to the new limits. Pressing the Cancel button disregards the new limits and returns to the map display.

Enter the Map Limits dialog box

The Save As menu option is used to specify the variable names in which to save the map data subset. To save line and patch data, enter the new latitude and longitude variable names, along with the map resolution. For surface data, enter the new map and referencing vector variable names, along with the scale of the map. Latitude and longitude limits are optional.

More About

collapse all

Line Style, Marker, and Color

Specify the line style, marker, and color as a character vector or string containing symbols. The symbols can appear in any order. You do not need to specify all three characteristics (line style, marker, and color). For example, specify a red dashed line using '--r'.

Line StyleDescriptionResulting Line
"-"Solid line

Sample of solid line

"--"Dashed line

Sample of dashed line

":"Dotted line

Sample of dotted line

"-."Dash-dotted line

Sample of dash-dotted line, with alternating dashes and dots

MarkerDescriptionResulting Marker
"o"Circle

Sample of circle marker

"+"Plus sign

Sample of plus sign marker

"*"Asterisk

Sample of asterisk marker

"."Point

Sample of point marker

"x"Cross

Sample of cross marker

"_"Horizontal line

Sample of horizontal line marker

"|"Vertical line

Sample of vertical line marker

"square"Square

Sample of square marker

"diamond"Diamond

Sample of diamond marker

"^"Upward-pointing triangle

Sample of upward-pointing triangle marker

"v"Downward-pointing triangle

Sample of downward-pointing triangle marker

">"Right-pointing triangle

Sample of right-pointing triangle marker

"<"Left-pointing triangle

Sample of left-pointing triangle marker

"pentagram"Pentagram

Sample of pentagram marker

"hexagram"Hexagram

Sample of hexagram marker

Color NameShort NameRGB TripletAppearance
"red""r"[1 0 0]

Sample of the color red

"green""g"[0 1 0]

Sample of the color green

"blue""b"[0 0 1]

Sample of the color blue

"cyan" "c"[0 1 1]

Sample of the color cyan

"magenta""m"[1 0 1]

Sample of the color magenta

"yellow""y"[1 1 0]

Sample of the color yellow

"black""k"[0 0 0]

Sample of the color black

"white""w"[1 1 1]

Sample of the color white

Version History

Introduced before R2006a

expand all

R2024b: Removed

The maptrim function has been removed. Use the geocrop or geoclip function instead.