lc2_agreement: A Latent Class Model for Agreement of Two Raters

View source: R/lc2_agreement.R

lc2_agreementR Documentation

A Latent Class Model for Agreement of Two Raters

Description

Estimates a latent class model for agreement of two raters (Schuster & Smith, 2006). See Details for the description of the model.

Usage

lc2_agreement(y, w=rep(1, nrow(y)), type="homo", method="BFGS", ...)

## S3 method for class 'lc2_agreement'
summary(object, digits=3,...)

## S3 method for class 'lc2_agreement'
logLik(object, ...)

## S3 method for class 'lc2_agreement'
anova(object, ...)

Arguments

y

A data frame containing the values of two raters in columns

w

Optional vector of weights

type

Type of model specification. Can be "unif", "equal", "homo" or "hete". See Details.

method

Optimization method used in stats::optim

...

Further arguments passed to stats::optim

object

Object of class l2_agreement

digits

Number of digits for rounding

Details

The latent class model for two raters decomposes a portion of ratings which conform to true agreement and another portion of ratings which conform to a random rating of a category. Let X_r denote the rating of rater r, then for i \neq j, it is assumed that

P(X_1=i, X_2=j)=\phi_{1i} \phi_{2j} ( 1 - \gamma )

For i=j it is assumed that

P(X_1=i, X_2=i)=\tau_i \gamma + \phi_{1i} \phi_{2i} ( 1 - \gamma )

where \gamma denotes the proportion of true ratings.

All \tau_i and \phi_{ri} parameters are estimated using type="hete". If the \phi parameters are assumed as invariant across the two raters (i.e. \phi_{1i}=\phi_{2i}=\phi_{i}), then type="homo" must be specified. The constraint \tau_i=\phi_i is imposed by type="equal". All \phi_i parameters are set equal to each other using type="unif".

Value

model_output

Output of the fitted model

saturated_output

Output of the saturated model

LRT_output

Output of the likelihood ratio test of model fit

partable

Parameter table

parmsummary

Parameter summary

agree_true

True agreement index shich is the \gamma parameter

agree_chance

Agreement by chance

rel_agree

Conditional reliability of agreement

optim_output

Output of optim from the fitted model

nobs

Number of observations

type

Model type

ic

Information criteria

loglike

Log-likelihood

npars

Number of parameters

y

Used dataset

w

Used weights

References

Schuster, C., & Smith, D. A. (2006). Estimating with a latent class model the reliability of nominal judgments upon which two raters agree. Educational and Psychological Measurement, 66(5), 739-747.

Examples

#############################################################################
# EXAMPLE 1: Dataset in Schuster and Smith (2006)
#############################################################################

data(data.immer08)
dat <- data.immer08

# select ratings and frequency weights
y <- dat[,1:2]
w <- dat[,3]

#*** Model 1: Uniform distribution phi parameters
mod1 <- immer::lc2_agreement( y=y, w=w, type="unif")
summary(mod1)

#*** Model 2: Equal phi and tau parameters
mod2 <- immer::lc2_agreement( y=y, w=w, type="equal")
summary(mod2)

## Not run: 
#*** Model 3: Homogeneous rater model
mod3 <- immer::lc2_agreement( y=y, w=w, type="homo")
summary(mod3)

#*** Model 4: Heterogeneous rater model
mod4 <- immer::lc2_agreement( y=y, w=w, type="hete")
summary(mod4)

#--- some model comparisons
anova(mod3,mod4)
IRT.compareModels(mod1,mod2,mod3,mod4)

## End(Not run)

immer documentation built on May 29, 2024, 11:52 a.m.