[QGIS-Developer] Possibility for Raster Natural Breaks Reclassification in QGIS

Bram Roozen bramroozen1997 at hotmail.com
Wed Apr 21 07:45:34 PDT 2021


Dear,

I am using PyQGIS in QGIS 3.10 and I am working on a script to standardise and automate heatmap creation. Currently, the only way (by my knowledge) to reclassify rasters in QGIS (through the Processing Toolbox) is with r.reclass or the SAGA reclassify values (simple and ‘not simple’). r.reclass only allows for an input text file with set numbers as intervals, which isn't optimal if an automated reclassification is desired based on data distribution. SAGA reclassify is only able to work with set values in a table. The same issue arises here with the inabilities for automated reclassification.

r.quant or r.quantiles also exists, but neither actually apply the quantiles for the raster to a new dataset.

In ArcPy, there is an option called ‘slice’ which exactly performs this trick. Is there a way that this can be achieved in QGIS/PyQGIS, so that automation can be achieved through the modeler, possibly with different reclassification methods (quantiles, equal intervals, natural breaks, etc)?

I hope that one will be able to answer this question. Thanks in advance.

Kind regards,
Bram Roozen


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20210421/ffdd3b73/attachment.html>


More information about the QGIS-Developer mailing list