llDiffT: Log-Likelihood Difference for the theta_i Parameters

View source: R/mederrRank.R

llDiffTR Documentation

Log-Likelihood Difference for the \theta_i Parameters

Description

This function computes the log-likelihood difference for the candidate \theta_i random effects. It is a helper function and not meant to be used on its own.

Usage

llDiffT(dat, thetai, cand, deltaj, gamma, sigma2)

Arguments

dat

data frame containing the observed sample counts.

thetai

vector of previous accepted values for the \theta_i random effects.

cand

vector of candidate values for the \delta_j random effects.

deltaj

vector of previous accepted values for the \delta_j random effects.

gamma

last sampled value for the \gamma parameter.

sigma2

last sampled value for the \sigma^2 parameter.

Details

For further details see Myers et al. (2011).

Value

llDiffT returns the vector of log-likelihood differences.

Author(s)

Sergio Venturini sergio.venturini@unicatt.it,

Jessica A. Myers jmyers6@partners.org

References

Myers, J. A., Venturini, S., Dominici, F. and Morlock, L. (2011), "Random Effects Models for Identifying the Most Harmful Medication Errors in a Large, Voluntary Reporting Database". Technical Report.

See Also

bhm.constr.resamp, bhm.mcmc, bhm.resample.


sergioventurini/mederrRank documentation built on Oct. 19, 2023, 12:40 a.m.