我坚持水包的能量平衡计算。我关注的示例代码位于此网站https://cran.r-project.org/web/packages/water/vignettes/Landsat8.html。我正在使用我自己的数据,能够用我感兴趣的领域(aoi)读取我的原始地图图像和表面反射图像。使用此代码时出现以下错误。
Energy.Balance <- METRIC.EB(image.DN = image, image.SR = image.SR,
plain=TRUE, aoi=aoi, n = 5, WeatherStation = WeatherStation,
ETp.coef = 1.2, sat="L8", alb.coeff = "Olmedo", LST.method = "SW",
LAI.method = "metric2010", Z.om.ws = 0.03, MTL = MTLfile)
Error in .local(x, ...):RasterLayer has no NA cells (for which to compute a distance)
答案 0 :(得分:0)
这在搜索锚点像素时听起来像个问题。您是否可以尝试更新最新版本的水包(0.7)并将anchors.method = 'flexible'
添加到功能METRIC.EB()
?