Description Usage Arguments Value
From the output of an MCMC chain, calculates the likelihood of observing each data point. This can then be used in loo::loo
1 2 | calculate_lik_matrix(chain, parTab, dat, f, N, nindiv = 3,
generate_labels = TRUE)
|
chain |
the MCMC chain with each row corresponding to an iteration |
parTab |
the parameter table used for this chain |
dat |
the data frame of data used to solve the likelihood |
f |
pointer to the model function used in the MCMC procedure |
N |
number of samples to take from the MCMC chain |
nindiv |
the number of individuals in each group/strain combination |
generate_labels |
if TRUE, generates labels to match each estimated k value to the correct data point. This only works if using data with an experimental design matching the protocol |
a matrix of same dimensions as dat
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.