ndbi {ASIP} | R Documentation |
Normalized Difference Built-up Index (NDBI) is used for mapping built-up areas
ndbi(directory = getwd(), crop = "n", ext2crop = "none")
ext2crop , crop , directory |
Same as mentioned in |
Computed NDBI product
1. NDBI= (r_swir1 - r_nir)/ (r_swir1 + r_nir)
where, "r_" denotes TOA reflectance band.
Other important notes are mentioned in custom.eqn
.
library (raster)
library (rgdal)
# Finding the path of the sample satellite image directory.
# User may define paths directly like "/home/ur_folder" or "C:/ur_folder"
path <- system.file ("TM_sample", package = "ASIP")
shapefil <- paste0 (path, "/test.shp")
op <- ndbi (directory = path, crop = "y", ext2crop = shapefil)