This is a simple operation I've done with other data sets on GEE but for some reason I can't get it to work with MODIS AOD.
Working off the example on Google's developer website...
var collection = ee.ImageCollection('MODIS/006/MCD19A2_GRANULES')
.select('Optical_Depth_047')
.filterDate('2019-01-01', '2019-01-15');
var band_viz = {
min: 0,
max: 500,
palette: ['black', 'blue', 'purple', 'cyan', 'green', 'yellow', 'red']
};
Map.addLayer(collection.mean(), band_viz, 'Optical Depth 047');
Map.setCenter(76, 13, 6);
We get a raster of mean AOD values
Next I want to plot the first raster from the collection.
var image = collection.first()
print(image)
Map.addLayer(image, band_viz, 'Optical Depth 047');
The image appears in the console and in the map legend, but is not visible on the map.
Here's the link to the script. Thanks!