I am new to GEE (about two weeks) and trying to understand the response of NDVI (as proxy for phenology) to temperature and precipitation in the Oban forest of Nigeria. I am using MOD13Q1 (250 m), MOD11A2 (1000 m), and Monthly GPM (11132 m) or TRMM 3B43 (27830 m).
I want to summarize the 16-day Modis data into monthly and yearly values, then export the values into R for further analysis (trend analysis, regression and lag in NDVI response to climate parameters (temperature and precipitation)).
I have been able to generate, set boundaries, scale, parse for QA and visualize the time series of the data in the current format.
var CRNP_Oban = ee.FeatureCollection("users/sijehasuk/CRNP_Oban2"),
ndvi = ee.ImageCollection("MODIS/061/MOD13Q1"),
lst_day = ee.ImageCollection("MODIS/061/MOD11A2");
// 1 ****************************************************************************
/////////////////////////////////////////////////
//// Extract MODIS NDVI data from 16-day MOD13Q1 250m resolution
// Creat Filter of quality pixels
var mask = function(im) {
return im.updateMask(im.select("SummaryQA").eq(0));
};
// Import NDVI data
var ndvi = ee.ImageCollection(ndvi)
.filterDate('2000-01-01','2020-01-01')
.map(mask)
.select("NDVI")
.filterBounds(CRNP_Oban);
//Rescale
var rescale = function(image) {
var temp = image.toFloat().multiply(0.0001);
image = image.addBands(temp);
return image;
};
var rescaleNDVI = ndvi.map(rescale);
// Charts NDVI time series (mean, max and min) ## NDVI_1 is the rescaled band
print(ui.Chart.image.series(rescaleNDVI.select("NDVI_1"), CRNP_Oban,
ee.Reducer.mean(), 250));
print(ui.Chart.image.series(rescaleNDVI.select("NDVI_1"), CRNP_Oban,
ee.Reducer.max(), 250));
print(ui.Chart.image.series(rescaleNDVI.select("NDVI_1"), CRNP_Oban,
ee.Reducer.min(), 250));
How can I summarize all data into a monthly (single mean image value) and yearly (single mean image value) format (possibly with the minimum, maximum and mean Reducers) that can be exported individually? The reason for the yearly data is to produce a yearly trend and do some regression analysis.
The Code can be accessed here: https://code.earthengine.google.com/?accept_repo=users/sijehasuk/stackexchange Asset can be accessed here: https://code.earthengine.google.com/?asset=users/sijehasuk/CRNP_Oban2
Update the question so it focuses on one problem only. This will help others answer the question. You can edit the question or post a new one.