I'm working with MERRA-2 data using xarray, and I'm attempting to plot data only over the Pacific Ocean. However, my data are in units of degrees East, such that the International Dateline is represented with index 0 and a value of -180, and the Prime Meridian/Greenwich Meridian is at index 288 (576/2) with a value approximating zero. To a rough estimation, the Pacific Ocean can be found in this coordinate system between 0 and 96, as well as from 480 to 575 (these indices corresponded to 120 E and 120 W, respectively.) How can I use .isel() (or .loc() or .sel(), if one of those is more appropriate) to choose JUST the region I'm describing?
For reference, the below picture is the result of using data.isel(lon=slice(96,480)).plot()
, which is my current best guess. Do I need to use a cyclic point? To my understanding, that would solve the opposite problem I have.