NDWI

摘要

计算多波段栅格对象的归一化差值水体指数 (NDWI),并返回具有该指数值的栅格对象。

说明

归一化差值水体指数 (NDWI) 方法是一个用于描绘和监测地表水内容变化的指标。 该指标使用 NIR 和绿光波段进行计算。

NDWI = (Green - NIR) / (Green + NIR)

有关其他多波段栅格索引的信息,请参见波段算术栅格函数。

栅格对象所引用的栅格数据集是临时性的。 要将其设置为永久,可以调用栅格对象的 save 方法。

语法

NDWI (raster, {nir_band_id}, {green_band_id})
参数说明数据类型
raster

The input raster.

Raster
nir_band_id

The band ID of the near-infrared band. The ID index uses one-based indexing.

(默认值为 5)

Integer
green_band_id

The band ID of the green band. The ID index uses one-based indexing.

(默认值为 3)

Integer
返回值
数据类型说明
Raster

具有 NDWI 指数值的输出栅格对象。

代码示例

NDWI 示例

计算 Sentinel-2 图像的归一化差异水体指数。

import arcpy

NDWI_raster = arcpy.sa.NDWI("Sentinel2.tif", 8, 3)

相关主题