maximum value of variable at particular latlong in timeseries nc file with spatial variation
Added by Suvarna Tikle over 1 year ago
Dear All,
I am working on nc file which consist of hourly data. Is it possible to find out the date on which my variable value is highest?
Example: My "trail.nc" consist of spatial hourly variation for the one month. I would like to find out the date with highest value of variable"PM" in the file at XLONG,106.7741,XLAT,-6.1214.
I tried with python but hard luck. Can we do it with cdo?
Your reply will be highly appreciable.
Thanks.
Best,
Suvarna
Replies (3)
RE: maximum value of variable at particular latlong in timeseries nc file with spatial variation - Added by Estanislao Gavilan over 1 year ago
Hi Suvarna,
there are a lot of examples about finding peaks and selecting data on this forum. You should try to find something similar to your case and edit it. Then, we can help you if you encounter any problem.
Kind regards,
Estanislao
RE: maximum value of variable at particular latlong in timeseries nc file with spatial variation - Added by Karin Meier-Fleischer over 1 year ago
Hi Suvarna,
in Python you can use the following:
dsloc = ds.sel(XLONG=106.7741, XLAT=-6.1214, method='nearest') dsloc.tr19_19[dsloc.tr19_19 == dsloc.tr19_19.max()].time
RE: maximum value of variable at particular latlong in timeseries nc file with spatial variation - Added by Suvarna Tikle over 1 year ago
Thanks a lot.