v1.9.0
reduceRegion for image collections
In this release, we introduced a much wanted feature to our collection of tools. Using this version you'll be able to perform feature enrichment and perform reduceRegion operation directly on top of you image collections. We tried to cover as many traps you could meet in the way and provide something as simple as possible to compute the same reduceRegion operation you would do on an image but across the stack.
import ee, geetools
## Import the example feature collection and drop the data property.
ecoregions = ee.FeatureCollection("projects/google/charts_feature_example").select(["label", "value", "warm"])
## Load MODIS vegetation indices data and subset of 4 images.
vegIndices = ee.ImageCollection("MODIS/061/MOD13A1").filter(ee.Filter.date("2010-01-01", "2010-02-28")).select(["NDVI", "EVI"])
vegIndices.geetools.reduceRegion(
reducer = ee.Reducer.mean(),
idProperty = "system:time_start",
idPropertyType = ee.Date,
geometry = ecoregions.filter(ee.Filter.eq("label", "Forest")).geometry(),
scale = 500
).getInfo(){
"2010-01-01T00-00-00": {"EVI": 1906.640549923878, "NDVI": 3271.6286118599337},
"2010-01-17T00-00-00": {"EVI": 3285.1954560181716, "NDVI": 7332.941022787698},
"2010-02-02T00-00-00": {"EVI": 2973.249133365389, "NDVI": 7853.778045715129},
"2010-02-18T00-00-00": {"EVI": 3278.830343157147, "NDVI": 7959.46303125494}
}More information and example in the documentation.
What's Changed
- fix: make sure every plot can be called without ax paramaters by @12rambau in #365
- fix: display doy graph using month start names by @12rambau in #364
- Fix profiler by @fitoprincipe in #376
ee.FeatureCollectiontoee.Dictionaryby @fitoprincipe in #373- feat: write a reduceRegion method for imageCollection by @12rambau in #359
- docs: run the notebooks dynamically by @12rambau in #379
Full Changelog: v1.8.0...v1.9.0