You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Computing an annual climatology from monthly means requires one to know the number of days in a month. Does this command know that information? How? It depends on leap-year or no-leap. Where is that information accessed?
As far as I know this method does not account for the number of days in each month and will weigh each month equally to calculate the annual mean. We should probably include the method where the number of days in each month are accounted for. I think you could use the xarray.DataArray.weighted() method to do that. If you have a separate array like delta_t (e.g., number of seconds) with the same time axis, you could use that to do the accurate weighting. That should also take care of distinguishing leap from no-leap years.
I suggest we offer something compatible with that tutorial so that MOM6 users can compute consistent monthly climatologies.
We know that equal weights is wrong (5-10% wrong), so should offer a proper approach. Weighted averages are commonly desired for other applications too, so this example could provide the template for others.
Computing an annual climatology from monthly means requires one to know the number of days in a month. Does this command know that information? How? It depends on leap-year or no-leap. Where is that information accessed?
https://github.com/raphaeldussin/MOM6-AnalysisCookbook/blob/3cf066aefe3d37e1ed57d8817f30e229138b366b/docs/notebooks/time_operations.ipynb#L233
The text was updated successfully, but these errors were encountered: