Mapping Toolbox    
angl2str

Convert angular values to strings

Syntax

Description

The purpose of this command is to make angular-valued variables into strings suitable for map display.

str = angl2str(angin) converts the input vector of angles, angin, to a string matrix.

str = angl2str(angin,format) uses the format string to specify the notation to be used with the string matrix. The default, 'none', results in simple numerical representation (no indicator for positive angles, minus signs for negative angles); 'pm' (for plus-minus) adds a `+' for positive angles; 'ns'
(for north-south) appends an `S' for negative angles and an 'N' for positive angles; 'ew' (for east-west) appends a `W' for negative angles and an `E' for positive angles.

str = angl2str(angin,format,units) uses the input units to define the angle units of the angin input. units is any valid angle string ('degrees' are the default). The units input also determines which unit symbol to suffix to the output strings.

str = angl2str(angin,format,units,digits) determines how many digits to display. digits is the power of 10 representing the last place of significance in the resulting output. For example, if digits = 2, the hundreds slot will be the last significant figure. In general, the 10digits slot will be the last significant figure, rounded appropriately depending upon the value in the 10digits-1 slot. digits is -2 by default.

Examples

Create a string matrix to represent a series of values in dms units, using the north-south format:

These LaTeX strings will be displayed (using either text or textm) as:

See Also

str2angle
Convert strings containing DMS formatted angles to numbers
angledim
Convert angle units
dist2str
Convert distance values to strings
time2str
Convert time values to strings


  almanac angledim