Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Selection by coordinates, python-xarray

I have a small python-xarray DataArray I call TINY with dimensions x,y, and t. TINY represents a processed subset of a larger DataSet I call HUGE with dimensions x',y' and t' and variables foo, bar and baz

I'm looking for a way to select a Dataset from HUGE using TINY coordinates.(all coordinates and coordinate pairs in tiny exist in huge)

I hastily drafted up the following illustration

enter image description here

The selection returns a subset of HUGE that shares the coords of TINY. What is returned is a DataSet. Is there some shorthand x-array method to handle this?

like image 209
Conic Avatar asked Sep 18 '25 21:09

Conic


1 Answers

.reindex_like() will give you HUGE's data over TINY's coordinates - is that what you're looking for?

like image 156
Maximilian Avatar answered Sep 20 '25 13:09

Maximilian