TransWikia.com

Deleting values less than 0.31 in NDVI raster layer in QGIS

Geographic Information Systems Asked by Ange on August 27, 2021

In my research I have a Ndvi raster layer, and I want to delete the values corresponding to bare soil, which are those minor of 0.31. Therefore, I will obtain a new raster layer with those values higher or equal to 0.31.

Could anybody help me with this?

I am using QGIS.

2 Answers

Use the Reclassify by Table on your NDVI layer where all values less than or equal to 0.31 get values of -9999 and all other values get a value of 1. Ensure -9999 is the no data value in the Reclassify by Table tool. Then, use the raster calculator to multiply you newly reclassified output by the original NDVI. The resulting layer will have no data values anyplace there was a 0.31 or less value and the original NDVI value if greater. Here is a link to the reclassify by table tool.

Answered by GBG on August 27, 2021

You cant delete values in a raster but you can set them to no data.

  1. Set values <0.31 to -5 and all other to the ndvi raster values using Raster calculator: ("ndvi@1"<0.31)*-5 + ("ndvi@1">=0.31)*"ndvi@1"

enter image description here

  1. Translate and set no data value to -5 enter image description here Result: enter image description here

(See: How to set all pixels with value <= 0 to "nodata" in DEM raster?)

Answered by BERA on August 27, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP