Class: QgsRasterMinMaxOrigin

Describes the origin of minimum and maximum values in a raster.

It does not store by itself the min/max values.

Enums

Extent

alias of RasterRangeExtent

Limits

alias of RasterRangeLimit

StatAccuracy

alias of RasterRangeAccuracy

Methods

cumulativeCutLower

Returns the lower bound of cumulative cut method (between 0 and 1).

cumulativeCutUpper

Returns the upper bound of cumulative cut method (between 0 and 1).

extent

Returns the raster extent.

limits

Returns the raster limits.

readXml

Deserialize object.

setCumulativeCutLower

Sets the lower bound of cumulative cut method (between 0 and 1).

setCumulativeCutUpper

Sets the upper bound of cumulative cut method (between 0 and 1).

setExtent

Sets the extent.

setLimits

Sets the limits.

setStatAccuracy

Sets the statistics accuracy.

setStdDevFactor

Sets the factor f so that the min/max range is [ mean - f * stddev , mean + f * stddev ]

statAccuracy

Returns the raster statistic accuracy.

stdDevFactor

Returns the factor f so that the min/max range is [ mean - f * stddev , mean + f * stddev ]

writeXml

Serialize object.

Static Methods

extentFromString

Deserialize Extent

extentString

Returns a string to serialize Extent

limitsFromString

Deserialize Limits

limitsString

Returns a string to serialize Limits

statAccuracyFromString

Deserialize StatAccuracy

statAccuracyString

Returns a string to serialize StatAccuracy

Attributes

CUMULATIVE_CUT_LOWER

Default cumulative cut lower limit

CUMULATIVE_CUT_UPPER

Default cumulative cut upper limit

DEFAULT_STDDEV_FACTOR

Default standard deviation factor

class qgis.core.QgsRasterMinMaxOrigin[source]

Bases: object

CUMULATIVE_CUT_LOWER: float = 0.02

Default cumulative cut lower limit

CUMULATIVE_CUT_UPPER: float = 0.98

Default cumulative cut upper limit

DEFAULT_STDDEV_FACTOR: float = 2.0

Default standard deviation factor

Extent

alias of RasterRangeExtent

Limits

alias of RasterRangeLimit

StatAccuracy

alias of RasterRangeAccuracy

cumulativeCutLower(self) float[source]

Returns the lower bound of cumulative cut method (between 0 and 1).

Return type:

float

cumulativeCutUpper(self) float[source]

Returns the upper bound of cumulative cut method (between 0 and 1).

Return type:

float

extent(self) Qgis.RasterRangeExtent[source]

Returns the raster extent.

Return type:

Qgis.RasterRangeExtent

static extentFromString(extent: str | None) Qgis.RasterRangeExtent[source]

Deserialize Extent

Parameters:

extent (Optional[str])

Return type:

Qgis.RasterRangeExtent

static extentString(extent: Qgis.RasterRangeExtent) str[source]

Returns a string to serialize Extent

Parameters:

extent (Qgis.RasterRangeExtent)

Return type:

str

limits(self) Qgis.RasterRangeLimit[source]

Returns the raster limits.

Return type:

Qgis.RasterRangeLimit

static limitsFromString(limits: str | None) Qgis.RasterRangeLimit[source]

Deserialize Limits

Parameters:

limits (Optional[str])

Return type:

Qgis.RasterRangeLimit

static limitsString(limits: Qgis.RasterRangeLimit) str[source]

Returns a string to serialize Limits

Parameters:

limits (Qgis.RasterRangeLimit)

Return type:

str

readXml(self, elem: QDomElement)[source]

Deserialize object.

Parameters:

elem (QDomElement)

setCumulativeCutLower(self, val: float)[source]

Sets the lower bound of cumulative cut method (between 0 and 1).

Parameters:

val (float)

setCumulativeCutUpper(self, val: float)[source]

Sets the upper bound of cumulative cut method (between 0 and 1).

Parameters:

val (float)

setExtent(self, extent: Qgis.RasterRangeExtent)[source]

Sets the extent.

Parameters:

extent (Qgis.RasterRangeExtent)

setLimits(self, limits: Qgis.RasterRangeLimit)[source]

Sets the limits.

Parameters:

limits (Qgis.RasterRangeLimit)

setStatAccuracy(self, accuracy: Qgis.RasterRangeAccuracy)[source]

Sets the statistics accuracy.

Parameters:

accuracy (Qgis.RasterRangeAccuracy)

setStdDevFactor(self, val: float)[source]

Sets the factor f so that the min/max range is [ mean - f * stddev , mean + f * stddev ]

Parameters:

val (float)

statAccuracy(self) Qgis.RasterRangeAccuracy[source]

Returns the raster statistic accuracy.

Return type:

Qgis.RasterRangeAccuracy

static statAccuracyFromString(accuracy: str | None) Qgis.RasterRangeAccuracy[source]

Deserialize StatAccuracy

Parameters:

accuracy (Optional[str])

Return type:

Qgis.RasterRangeAccuracy

static statAccuracyString(accuracy: Qgis.RasterRangeAccuracy) str[source]

Returns a string to serialize StatAccuracy

Parameters:

accuracy (Qgis.RasterRangeAccuracy)

Return type:

str

stdDevFactor(self) float[source]

Returns the factor f so that the min/max range is [ mean - f * stddev , mean + f * stddev ]

Return type:

float

writeXml(self, doc: QDomDocument, parentElem: QDomElement)[source]

Serialize object.

Parameters:
  • doc (QDomDocument)

  • parentElem (QDomElement)