QGIS – How to Get the Absolute Value of a Raster Cell

qgisreclassify

I have a raster map (-100 to +100) and I need to get all the minus values as absolute values (-100=100; -99=99…). How can I do this? Is it something like reclassify?

Best Answer

You could use the Raster Calculator to do this. Square the pixel values to ensure all values are positive, and then extract the square roots to get back original number. Something like this:

sqrt ( myraster@1 * myraster@1 )
Related Question