iridl / python-maprooms

Dash maprooms and tools
0 stars 4 forks source link

ideas for clim and ano calculations using groupby #375

Open remicousin opened 1 year ago

remicousin commented 1 year ago

Ideas to do "daily climatology" and back from clim to real time to, for instance, compute anomalies.

There is a function and a test. Test isn't really test but rather how I envision the usage (or what would be inside functions easier for the user to call). dayofyear366 function creates the groups for climatologies.

Should we be given a 365-day climato, it would be easy to project it to a 366-day one such as the one I created and fill Feb 29 with something and have the user have a few options about what to fill with.

Also with this set up, we need not create functions for each climato/ano analysis (e.g. clim: mean, stddev...; ano: subtract, divide...), but can describe the process in documentation, or make functions calling functions (this time allowing users to see them): climato(daily_data, [func1, func2...]) ano(daily_data, [func1, func2...])

(also, this is not necessarily meant to merge: this is playground.... I thought there was a label or something for that but now I can't see it)