fit_em: Fit coding models via an EM algorithm

Description Usage Arguments

View source: R/em_algorithm.R

Description

Estimates parameters of either a BACE, MACE, or DS coding model using coder-object labels

Usage

1
2
3
4
5
6
7
fit_em(
  long_labels,
  model = "BACE",
  max_iter = 1000,
  tol = 1e-06,
  verbose = FALSE
)

Arguments

long_labels

should be a data frame with columns:

  • "ii"object index

  • "jj"coder index

  • "yy"the coder's label for that object

because long_labels is in long format, there shouldn't be any missing data

model

one of c("BACE", "DS", "MACE")

max_iter

maximum number of iterations for the EM algorithm; I would advise not touching this unless you know what you are doing.

tol

the algorithm is terminated once the change in average log likelihood (average taken at the object level) is both positive and less than tol.

verbose

if TRUE, the function will print status updates during the EM algorithm.


matthewtyler/CodingModels documentation built on June 20, 2021, 9:57 a.m.