});

custom-scripts

A repository of custom scripts that can be used with Sentinel-Hub services.

Normalized difference vegetation index

Show script or download it.

Evaluate and visualize

General description

The well known and widely used NDVI is a simple, but effective index for quantifying green vegetation. It normalizes green leaf scattering in Near Infra-red wavelengths with chlorophyll absorption in red wavelengths.

The value range of the NDVI is -1 to 1. Negative values of NDVI (values approaching -1) correspond to water. Values close to zero (-0.1 to 0.1) generally correspond to barren areas of rock, sand, or snow. Low, positive values represent shrub and grassland (approximately 0.2 to 0.4), while high values indicate temperate and tropical rainforests (values approaching 1). It is a good proxy for live green vegetation; see [1] for details.

The normalized difference vegetation index, abbreviated NDVI, is defined as

\[NDVI := \mathtt{Index}(NIR,RED) = \frac{NIR-RED}{NIR+RED}.\]

For Sentinel-2, the index looks like this:

\[NDVI := \mathtt{Index}(B8,B4) = \frac{B8-B4}{B8+B4}.\]

NDVI for other datasets:

Landsat 8 NDVI = (B05 - B04) / (B05 + B04)

Landsat 5 and 7 NDVI = (B04 - B03) / (B04 + B03)

MODIS NDVI = (B02 - B01) / (B02 + B01)

ENVISAT MERIS NDVI = (B13 - B07) / (B13 + B07)

Description of representative images

NDVI of Rome. Acquired on 8.10.2017.

NDVI of Rome

Color legend

NDVI range HTLM color code Color
NDVI < -0.2 #000000
-.2 < NDVI ≤ 0 #a50026
0 < NDVI ≤ .1 #d73027
.1 < NDVI ≤ .2 #f46d43
.2 < NDVI ≤ .3 #fdae61
.3 < NDVI ≤ .4 #fee08b
.4 < NDVI ≤ .5 #ffffbf
.5 < NDVI ≤ .6 #d9ef8b
.6 < NDVI ≤ .7 #a6d96a
.7 < NDVI ≤ .8 #66bd63
.8 < NDVI ≤ .9 #1a9850
.9 < NDVI ≤ 1.0 #006837

References

[1] Wikipedia, Normalized Difference Vegetation Index . Accessed on October 4th 2017.