The resulting coefficient matrix is based on the number of rows in Value which must be in 5-year age groups (not abridged). The final row may be an open or closed age group, as indicated by the OAG argument.

graduate_beers_expand(Value, OAG = FALSE, method = "Mod")

Arguments

Value

numeric vector, presumably counts in grouped ages

OAG

logical, default = TRUE is the final age group open?

method

character. Valid values are "mod" or "ord". Default "mod".

Details

The Value vector is a placeholder in this case. This function is a utility called by the Beers family of functions, where it is most convenient to just pass in the same matrix being used in those calculations to determine the layout of the coefficient matrix.

References

Beers HS (1945). “Modified-interpolation formulas that minimize fourth differences.” Record of the American Institute of Actuaries, 34(69), 14--20. Siegel Jacob S, Swanson David A (eds.) (2004). The Methods and Materials of Demography, 2 edition. Elsevier Academic Press, California, USA, San Diego, USA.

Examples

coefsOA <- graduate_beers_expand(pop5_mat, OAG = TRUE, method = "mod") coefsclosed <- graduate_beers_expand(pop5_mat, OAG = FALSE, method = "mod") dim(graduate_beers_expand(pop5_mat, TRUE))
#> [1] 521 105
dim(graduate_beers_expand(pop5_mat, FALSE))
#> [1] 525 105
coefso <- graduate_beers_expand(pop5_mat, OAG = TRUE, method = "ord") # how to use (under the hood in beers()