inst/data-raw/inv_sigma_delta_hat.R

# Get variance-covariance matrix (sigma_delta) of the spline coefficient parameters for the local model

# Step 1:
# First run a multi-country model (using the `run_model` function) and save the results to a .RDS file

# Step 2: Pull out and save variance-covariance matrix for use in single-country model.
mod <- readRDS("mod_global_subnational.RDS") # Read in multi-country MCMC results
inv.sigma_delta_hat_subnationalmod <- mod$BUGSoutput$median$inv.sigma_delta
usethis::use_data(inv.sigma_delta_hat_subnationalmod, overwrite=TRUE)

Try the mcmsupply package in your browser

Any scripts or data that you put into this service are public.

mcmsupply documentation built on May 29, 2024, 11:15 a.m.