I have downloaded data from LANDSAT 8. I want to create a layer for NDVI. I have read several sources on using the bands for creating the raster.
I started with this:
Calculating NDVI in ArcGIS 10 - Thad Wester
I followed the steps and each time my raster was not what I expected. Then I noticed the NDVI option in the Image Analysis Window and tried that. The resulting raster looks like what I expect, almost all green, since I am looking at a forest. However, the values range from 1 - 100something, when they are supposed to be -1 to 1 at most, so that output is suspect to me.
I searched some more for how to come up with the raster and found this:
I still can't find the Band Arithmetic function. I rely on the GUI, I don't know anything about programming, so if it's not a distinct tools or menu item, I don't know how to access it.
Looking at the explanation here
it says that the IR and red bands are defaulted to 3 and 4. I didn't know which was which, Wikipedia says that LANDSAT 8 breaks down where IR is 5 and red is 4. Options lets me change that and I did, but no matter what I do, I can't get a raster that I expect. I've tried Image Analysis Window with different methods and raster calculator under Spatial Analyst.
And I saw this:
Is there a problem with ndvi function in ArcMap 10.2? Not getting expected results.
I am not sure what step to take next.
Solved! Go to Solution.
Regarding values of 1-100+:
You can scale the values 0 -> 255 to -1 -> 1, using a formula like: ((value/255) * 2) - 1
Regarding values of 1-100+:
You can scale the values 0 -> 255 to -1 -> 1, using a formula like: ((value/255) * 2) - 1
Thank you, Darren.
Hi Darren,
I am using Sentinel 2, Landsat 8 and MODIS data.
My NDVI value for Sentinel is between 0-255 as well. Do you know why this trasnformation is done for Sentinel's NDVI value?
Is there a way to scale sentinel's data before any calculations so no more scaling is needed afterwards? I know for Landsat and MODIS the scaling is *0.0001.
Because I need to calculate GVMI ((NIR+0.1)-(SWIR-0.02))/(((NIR+0.1)+(SWIR-0.02)) so I am wondering how to apply the "0.1" and "0.02". Should I use the same formula as NDVI?
I would be so thankful if you could help with this.
Just following up on how to calculate NDVI through the Raster Calculator:
The basic formula is : (NIR-VisRed)/(NIR+VisRed), where NIR = near-infrared band (or raster) and VisRed = visible red band (or raster).
There are two tricky parts to using this formula in Raster Calculator:
1.) You will likely want to specify an individual raster band (or bands) within a multiband raster. You can only do this using the full file path in (10.1 at least), appending "\Band_1" (or other band number) to the end. For example, this would point to band 5 in a raster stored in "C:/rasters/raster.tiff": "C:/rasters/raster.tiff/Band_5"
2.) Your bands are likely integer rasters. An integer raster plus, minus, multiplied, or divided by another integer raster results in an integer raster. However, an integer raster operated by a floating point raster results in a floating point raster. We want a floating point NDVI layer in the end, so we must cast at least one of the integer rasters to floating point (the floating point will propagate through the formula). You can cast an integer to floating point using "Float(raster)" (note the capital "F").
In the example below, I have a one-band NIR raster loaded in ArcMap and an RGB colour raster, from which I pull the red band.
(Float("0015_nir.tiff") - "C:\rasters\0015_rgb.tiff\Band_1")/("0015_nir.tiff" + "C:\rasters\0015_rgb.tiff\Band_1")
You can calculate NDVI in arcgis, here help you calculate NDVI in ArcGIS - YouTube