- X 軸 = xProperty でラベル付けされた画像(デフォルト: 'system:time_start')。
- Y 軸 = Reducer の出力。
- Series = seriesProperty でラベル付けされたリージョン(デフォルト: 'system:index')。
グラフを返します。
用途 | 戻り値 |
---|---|
ui.Chart.image.seriesByRegion(imageCollection, regions, reducer, band, scale, xProperty, seriesProperty) | ui.Chart |
引数 | タイプ | 詳細 |
---|---|---|
imageCollection | ImageCollection | グラフに含めるデータを含む ImageCollection。 |
regions | Feature|FeatureCollection|Geometry|List<Feature>|List<Geometry> | 削減するリージョン。 |
reducer | レデューサ | Y 軸の値を生成するリデューサー。単一の値を返す必要があります。 |
band | 数値|文字列、省略可 | リデューサーを使用して削減するバンド名。デフォルトは最初のバンドです。 |
scale | 数値、省略可 | リデューサーで使用するスケール(メートル単位)。 |
xProperty | 文字列、省略可 | X 軸の各画像のラベルとして使用するプロパティ。デフォルトは「system:time_start」です。 |
seriesProperty | 文字列、省略可 | 系列ラベルに使用する opt_regions の特徴のプロパティ。デフォルトは「system:index」です。 |
例
コードエディタ(JavaScript)
// Define regions of pixels to reduce and chart a time series for. var regions = ee.FeatureCollection([ ee.Feature( ee.Geometry.BBox(-121.916, 37.130, -121.844, 37.076), {label: 'Forest'}), ee.Feature( ee.Geometry.BBox(-122.438, 37.765, -122.396, 37.800), {label: 'Urban'}) ]); // Define an image collection time series to chart, MODIS vegetation indices // in this case. var imgCol = ee.ImageCollection('MODIS/006/MOD13A1') .filter(ee.Filter.date('2015-01-01', '2020-01-01')) .select(['NDVI', 'EVI']); // Define the chart and print it to the console. var chart = ui.Chart.image.seriesByRegion({ imageCollection: imgCol, band: 'NDVI', regions: regions, reducer: ee.Reducer.mean(), scale: 500, seriesProperty: 'label', xProperty: 'system:time_start' }) .setOptions({ title: 'Average NDVI Value by Date', hAxis: {title: 'Date', titleTextStyle: {italic: false, bold: true}}, vAxis: { title: 'NDVI (x1e4)', titleTextStyle: {italic: false, bold: true} }, lineWidth: 5, colors: ['0f8755', '808080'], }); print(chart);