Allow dict for methods in xarray.Dataset.interp #5818
Unanswered
andypbarrett
asked this question in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I've been using interp to reproject and resample reanalysis data in lat-lon grids to projected coordinates. It works great!
However, I have one DataArray with categorical data (precipitation type) that is still numeric. This requires nearest-neighbour interpolation rather than (bi)linear interpolation. It would be nice to be able to do something like.
dataset.interp(latitude=new_lats, longitude=new_lons, method={'t2m': 'linear', 'ptype': 'nearest'})
Cheers
Andy
Beta Was this translation helpful? Give feedback.
All reactions