Description Usage Arguments Details Value Author(s) References Examples
computes several indices based on RGB bands
1 | vegInd_RGB(rgb, red = NULL, green = NULL, blue = NULL, indlist = "all")
|
rgb |
a RasterStack with RGB bands |
red |
the band/layer number of band 'red' |
green |
the band/layer number of band 'green' |
blue |
the band/layer number of band 'blue' |
indlist |
comma-separated character combinations of the desired indices. Select from "VVI","VARI","NDTI","RI","CI","BI","SI","HI","TGI","GLI","NGRDI", default=all. See details |
"VVI" Visible Vegetation Index (1 - abs((red - 30) / (red + 30))) * (1 - abs((green - 50) / (green + 50))) *(1 - abs((blue - 1) / (blue + 1)))
"VARI" Visible Atmospherically Resistant Index (green-red)/(green+red-blue)
"NDTI" Normalized Difference Turbidity Index (red-green)/(red+green)
"RI" Redness index (red2/(blue*green3)
"CI" Soil Colour Index (red-green)/(red+green)
"BI" Brightness Index sqrt((red2+green2+blue*2)/3)
"SI" Spectra Slope Saturation Index (red-blue)/(red+blue)
"HI" Primary Colours Hue Index (2*red-green-blue)/(green-blue)
"TGI" Triangular Greenness Index (-0.5*(190*(red - green)- 120*(red - blue))
"GLI" Green Leaf Index (2green-red-blue)/(2green+red+blue)
"NGRDI" Normalized Green Red Difference Index (green-red)/(green+red)
returns a RasterStack with the selected indices
Andreas Schönberg
The IDB Project (2020): Index Database (https://www.indexdatabase.de/)
1 2 3 4 5 6 7 8 9 10 11 | ### load data
extpath <-system.file("extdata","lau_mspec.tif",package = "LEGION")
mspec <- raster::stack(extpath)
names(mspec)<- c("blue","green","red","nir")
### compute all vegetation indizes
x <-LEGION::vegInd_RGB(mspec,3,2,1)
plot(x)
### select specific vegetation indices
vi <-c("VVI","SI","GLI")
y <-LEGION::vegInd_RGB(mspec,3,2,1,indlist=vi)
plot(y)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.