Description
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Similarly to the 'construct' method for Rolling objects, I think it will make sense to have the same for Coarsen objects.
My use will be for my da:
da(lon, lat, time) of dimension (2000, 1600, 240)
I wish to coarsen the data by a factor 4 in lon and lat (Lon and Lat), but wish to keep the data in a new dimension, it would be:
da(Lon, Lat, time, samples) of dim (500, 400, 240, 16)
my aim is to do da.median(dim=['time','samples'])
Describe the solution you'd like
A clear and concise description of what you want to happen.
da.coarsen(lon=4, lat=4, , boundary="trim").construct('samples')
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
I am using Rolling objects, but it increases the size of the matrix.
Many thanks for your work