【发布时间】:2017-12-16 18:00:08
【问题描述】:
我是编码新手,刚开始使用 Google 地球引擎代码编辑器。 我在 Google 地球引擎提供的 Lab 2 中:https://docs.google.com/document/d/1NojoqhGbsBnIWE2OSwYCgMmRxeZDn7F1g3kkNuMGJ1E/edit
当完成对数字 1.a.v 的实际操作时。我得到两个错误。
查看下面的完整代码:
var myd09 = ee.ImageCollection('MODIS/006/MYD09GA');
// Define a region of interest as a point at SFO airport.
var sfoPoint = ee.Geometry.Point(-122.3774, 37.6194);
// Center the map at that point.
Map.centerObject(sfoPoint, 16);
// Get a surface reflectance image from the MODIS MYD09GA collection.
var modisImage = ee.Image(myd09.filterDate('2011-08-28').first());
// Use these MODIS bands for red, green, blue, respectively.
var modisBands = ['sur_refl_b01', 'sur_refl_b04', 'sur_refl_b03'];
// Define visualization parameters for MODIS.
var modisVis = {bands: modisBands, min: 0, max: 3000};
// Add the MODIS image to the map.
Map.addLayer(modisImage, modisVis, 'MODIS');
// Get the scale of the data from the first band's projection:
var modisScale =
modisImage.select('sur_refl_b01').projection().nominalScale();
print('MODIS scale:', modisScale);
我收到的错误是:
1) 编号(错误) Image.select:参数“输入”是必需的。 2) MODIS: Layer error: Asset is not an Image or ImageCollection.
有没有人可以帮助我解决问题或指出正确的方向!
谢谢, 哈里特·威尔逊
【问题讨论】: