ArcGIS – How to Enforce Float Values for NDVI in ArcGIS

arcgis-desktoplandsatlandsat-5ndviraster-calculator

enter image description hereI am trying to calculate NDVI from Landsat 4-5 TM imagery (of the year 2008) using the formula NDVI = (band4-band3)/(band4+band3) from Raster Calculator of ArcGIS 10.4.1.
The problem that I am facing is that the resultant raster that I am getting has integer values. I want float values that stretch from -1 to +1.
How can I resolve the issue?

Best Answer

You need to ensure the output raster contains floating point bit depth. Here is how you would accomplish that in the raster calculator:

(Float(B4)-Float(B3))/(Float(B4)+Float(B3))

If you do not explicitly define floating point values in your equation, ArcGIS will assume you want integer values.

Related Question