posterior_samples: Extract Posterior Samples

Description Usage Arguments Details Value Examples

View source: R/posterior_samples.R

Description

Extract posterior samples from an object of class blsmeta

Usage

1
posterior_samples(object, param = NULL, print_names = FALSE)

Arguments

object

An object of class blsmeta.

param

character string. The parameter(s) to be extracted. See Details

print_names

logical. Should the parameter names be printed (defaults to FALSE)? This is useful for seeing which parameters can be extracted.

Details

Options for param depend on the model, but can included printed out by setting print_names = TRUE.

Note the variance components, and log-linear coefficients are on the standard deviation scale.

Value

A iter * chains by parameter matrix of posterior samples

Examples

1
2
3
4
5
6
7
8
9
library(psymetadata)

fit <-  blsmeta(yi = yi, 
                vi = vi, 
                es_id = es_id,
                data = gnambs2020)
                
posterior_samples(object = fit, 
                  print_names = TRUE)

donaldRwilliams/blsmeta documentation built on Dec. 20, 2021, 12:12 a.m.