Stretch

Command line (1)

The Stretch operation can be directly executed by typing one of the following expressions on the command line of the Main window:

  

OUTMAP

=

MapStretchLinear(InputMapName, Range from, Domain)

OUTMAP

=

MapStretchLinear(InputMapName, Range from, Domain, Range to)

OUTMAP

=

MapStretchHistEq(InputMapName, Range from, Intervals)

where:

OUTMAP

is the name of your output raster map.

MapStretchLinear

is the command to start the Stretch operation with linear stretching.

MapStretchHistEq

is the command to start the Stretch operation with histogram equalization.

InputMapName

is the name of your input raster map (must be a value map).

Range from

is the range of input values that should be stretched. Specify the 'stretch from range' as:

min:max |perc

min:max

lower and upper 'stretch from' boundaries

perc

real value >= 0, percentage of pixels to be ignored on both sides of the input map's histogram during stretching.

Domain

For linear stretching:
when choosing output domain Image, the output stretch range is from 0 to 255;
when choosing any other output value domain, specify the minimum and maximum values to stretch to (value range) and a precision (resolution of output values).

Range to

For linear stretching when choosing an output Value domain but not Image: the range of output values to which the 'range from' values need to be stretched. Specify the 'stretch to' range as:

min:max | min:max:precision

min:max

Lower and upper 'stretch to' values in output map.

min:max:precision

Lower and upper 'stretch to' values in output map, and precision of output values.

Intervals

For histogram equalization: the number of output intervals:

when 256 intervals are specified, the output values will range from 0 to 255;
when another number of output intervals is specified, the first interval will obtain output value 1, the second value 2, etc.

 

Tip: To use this operation on all raster maps in a map list, see Stretch : command line (2).

When the definition symbol = is used, a dependent output map is created; when the assignment symbol := is used, the dependency link is immediately broken after the output map has been calculated.

See also: