carpet_concentrations.gridders.latitude_seasonality_gridder
Gridder based on pre-calculated latitudinal gradient and seasonality
LatitudeSeasonalityGridder
- class LatitudeSeasonalityGridder(gridding_values, seasonality_name='seasonality', latitudinal_gradient_name='latitudinal_gradient')[source]
Bases:
objectGridder based on specified latitudinal gradient and seasonality
- calculate(global_means)[source]
Calculate gridded values
- Parameters
global_means (
xarray.core.dataset.Dataset) – Global-mean values. These should have already been interpolated such that their dimensions are("year", "month")(other dimensions e.g."scenario"are also ok) to obtain sensible results (if not, there may be jumps at the start and end of years).global_meansshould have also already been turned into a pint-compatiable quantity usingpint.quantifyor similar.- Returns
xarray.core.dataset.Dataset– Gridded values on a("latitude", "year", "month")grid (plus any other dimensions present inglobal_means)- Raises
CoordinateError –
global_meansdoes not have at least the dimensions of("year", "month")(other dimensions e.g."scenario"are also ok)NotPintQuantifiedError –
global_meanshas not been quantified usingpint.quantifyor similar
Notes
Eq. 1 of Meinshausen et al.1. We use slightly different notation here for clarity.
\[C(l, m, y, ...) = \overline{C(m, y, ...)} + S(l, m, y) + L(l, m, y)\]i.e. the concentration at latitude \(l\) in year \(y\) and month \(m\) is the sum of the global-, annual-mean concentration in that year (already interpolated down to a monthly timestep), the seasonality at that latitude in that year in that month (varies with year and latitude as often scaled with something else) and the latitudinal gradient at that latitude in that year and month (varies with year and month as often scaled with something else, must have monthly information to avoid step changes in output). Note that the global-, annual-mean concentrations \(C(y, m)\) must be pre-interpolated onto monthly steps using a mean-preserving alogrithm [#11 for function which will do this] to avoid spurious steps in the outputs.
The ellipses represent extra dimensions (e.g. scenario, greenhouse gas) that might be in \(C(y, m)\). Any such dimensions are preserved in the output.
-
gridding_values:
xarray.core.dataset.Dataset Values to use to convert global-mean concentrations to a grid
This should have already been turned into a pint-compatiable quantity using
pint.quantifyor similar. It should also contain variables that match the value ofseasonality_nameandlatitudinal_gradient_name. Both the variables must have at least the dimensions (“year”, “month”, “lat”). The seasonality variable must have an annual-mean of zero. The latitudinal gradient must have a spatial-mean of zero.
- 1
M. Meinshausen, E. Vogel, A. Nauels, K. Lorbacher, N. Meinshausen, D. M. Etheridge, P. J. Fraser, S. A. Montzka, P. J. Rayner, C. M. Trudinger, P. B. Krummel, U. Beyerle, J. G. Canadell, J. S. Daniel, I. G. Enting, R. M. Law, C. R. Lunder, S. O’Doherty, R. G. Prinn, S. Reimann, M. Rubino, G. J. M. Velders, M. K. Vollmer, R. H. J. Wang, and R. Weiss. Historical greenhouse gas concentrations for climate modelling (cmip6). Geoscientific Model Development, 10(5):2057–2116, 2017. URL: https://gmd.copernicus.org/articles/10/2057/2017/, doi:10.5194/gmd-10-2057-2017.