Class: QgsRasterMinMaxOrigin

This class describes the origin of min/max values. It does not store by itself the min/max values.

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

CumulativeCut

CurrentCanvas

DEFAULT_STDDEV_FACTOR

Default standard deviation factor

Estimated

Exact

MinMax

None_

StdDev

UpdatedCanvas

WholeRaster

class qgis.core.QgsRasterMinMaxOrigin[source]

Bases: object

CUMULATIVE_CUT_LOWER = 0.02

Default cumulative cut lower limit

CUMULATIVE_CUT_UPPER = 0.98

Default cumulative cut upper limit

CumulativeCut = 3
CurrentCanvas = 1
DEFAULT_STDDEV_FACTOR = 2.0

Default standard deviation factor

Estimated = 1
Exact = 0
class Extent

Bases: int

class Limits

Bases: int

MinMax = 1
None_ = 0
class StatAccuracy

Bases: int

StdDev = 2
UpdatedCanvas = 2
WholeRaster = 0
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) QgsRasterMinMaxOrigin.Extent[source]

Returns the raster extent.

Return type:

QgsRasterMinMaxOrigin.Extent

static extentFromString(extent: str | None) QgsRasterMinMaxOrigin.Extent[source]

Deserialize Extent

Parameters:

extent (Optional[str])

Return type:

QgsRasterMinMaxOrigin.Extent

static extentString(extent: QgsRasterMinMaxOrigin.Extent) str[source]

Returns a string to serialize Extent

Parameters:

extent (QgsRasterMinMaxOrigin.Extent)

Return type:

str

limits(self) QgsRasterMinMaxOrigin.Limits[source]

Returns the raster limits.

Return type:

QgsRasterMinMaxOrigin.Limits

static limitsFromString(limits: str | None) QgsRasterMinMaxOrigin.Limits[source]

Deserialize Limits

Parameters:

limits (Optional[str])

Return type:

QgsRasterMinMaxOrigin.Limits

static limitsString(limits: QgsRasterMinMaxOrigin.Limits) str[source]

Returns a string to serialize Limits

Parameters:

limits (QgsRasterMinMaxOrigin.Limits)

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: QgsRasterMinMaxOrigin.Extent)[source]

Sets the extent.

Parameters:

extent (QgsRasterMinMaxOrigin.Extent)

setLimits(self, limits: QgsRasterMinMaxOrigin.Limits)[source]

Sets the limits.

Parameters:

limits (QgsRasterMinMaxOrigin.Limits)

setStatAccuracy(self, accuracy: QgsRasterMinMaxOrigin.StatAccuracy)[source]

Sets the statistics accuracy.

Parameters:

accuracy (QgsRasterMinMaxOrigin.StatAccuracy)

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) QgsRasterMinMaxOrigin.StatAccuracy[source]

Returns the raster statistic accuracy.

Return type:

QgsRasterMinMaxOrigin.StatAccuracy

static statAccuracyFromString(accuracy: str | None) QgsRasterMinMaxOrigin.StatAccuracy[source]

Deserialize StatAccuracy

Parameters:

accuracy (Optional[str])

Return type:

QgsRasterMinMaxOrigin.StatAccuracy

static statAccuracyString(accuracy: QgsRasterMinMaxOrigin.StatAccuracy) str[source]

Returns a string to serialize StatAccuracy

Parameters:

accuracy (QgsRasterMinMaxOrigin.StatAccuracy)

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)