Google Earth Engine – Changing Max Band Value of Sentinel 5P Methane in GEE

bandgoogle-earth-enginemapping

I am working on GEE using Sentinel 5P methane dataset. The min and max band value for this dataset is 1750 and 1900 ppb respectively. When I run the code using this value, I get majority areas to be in max value region, i.e., red color. Can I change this default band value so that I can see a pattern in the map? The following is the code I used:

var CH4 = ee.ImageCollection("COPERNICUS/S5P/OFFL/L3_CH4")

var ROI = table.filter(ee.Filter.eq('country_co','IN'))
Map.addLayer(ROI)
Map.centerObject(ROI,10)

var CH4bands = CH4.select('CH4_column_volume_mixing_ratio_dry_air')

var image = CH4bands.filterBounds(ROI)

var CH4filterdate = image.filterDate('2022-01-01','2022-02-28')

var percentileCH4 = CH4filterdate.reduce(ee.Reducer.percentile([60]))

var band_viz = {
  min: 1750,
  max: 1900,
  palette: ['black', 'blue', 'purple', 'cyan', 'green', 'yellow', 'red']
};

var study_area = percentileCH4.clip(ROI)

Map.addLayer(study_area, band_viz)

Link: https://code.earthengine.google.com/9c9adeecb74679a3b921f105ab1d07ca

Best Answer

Rather than change the values of the band, you can change how the values are stretched when displaying.

In the corner of the map, click the gear next to your layer. Where it says custom choose an option. Play with that until you have one you like, then you can copy those values into your script. Visualization parameters for a layer

Here's what the above setting looks like. It's the 2 sigma stretch.

enter image description here