Observed Data Log-Likelihood Function for Estimation of the Naive Two-Stage Misclassification Model
naive_loglik_2stage.Rd
Observed Data Log-Likelihood Function for Estimation of the Naive Two-Stage Misclassification Model
Usage
naive_loglik_2stage(
param_current,
X,
V,
obs_Ystar_matrix,
obs_Ytilde_matrix,
sample_size,
n_cat
)
Arguments
- param_current
A numeric vector of regression parameters, in the order \(\beta, \delta\). The \(\delta\) vector is obtained from the matrix form. In matrix form, the gamma parameter matrix rows correspond to parameters for the \(\tilde{Y} = 1\) observed outcome, with the dimensions of
V
. In matrix form, the gamma parameter matrix columns correspond to the true outcome categories \(j = 1, \dots,\)n_cat
. The numeric vectordelta_v
is obtained by concatenating the delta matrix, i.e.delta_v <- c(delta_matrix)
.- X
A numeric design matrix for the first-stage observed mechanism.
- V
A numeric design matrix for the second-stage observed mechanism.
- obs_Ystar_matrix
A numeric matrix of indicator variables (0, 1) for the first-stage observed outcome
Y*
. Rows of the matrix correspond to each subject. Columns of the matrix correspond to each observed outcome category. Each row should contain exactly one 0 entry and exactly one 1 entry.- obs_Ytilde_matrix
A numeric matrix of indicator variables (0, 1) for the second-stage observed outcome \(\tilde{Y}\). Rows of the matrix correspond to each subject. Columns of the matrix correspond to each observed outcome category. Each row should contain exactly one 0 entry and exactly one 1 entry.
- sample_size
Integer value specifying the number of observations in the sample. This value should be equal to the number of rows of the design matrix,
X
orV
.- n_cat
The number of categorical values that the first- and second-stage outcomes, \(Y^*\) and \(\tilde{Y}\), can take.