perfect_sensitivity_EM {COMBO}  R Documentation 
Code is adapted by the SAMBA R package from Lauren Beesley and Bhramar Mukherjee.
perfect_sensitivity_EM(
Ystar,
Z,
X,
start,
beta0_fixed = NULL,
weights = NULL,
expected = TRUE,
tolerance = 1e07,
max_em_iterations = 1500
)
Ystar 
A numeric vector of indicator variables (1, 0) for the observed
outcome 
Z 
A numeric matrix of covariates in the true outcome mechanism.

X 
A numeric matrix of covariates in the observation mechanism.

start 
Numeric vector of starting values for parameters in the true
outcome mechanism ( 
beta0_fixed 
Optional numeric vector of values of the observation mechanism
intercept to profile over. If a single value is entered, this corresponds to
fixing the intercept at the specified value. The default is 
weights 
Optional vector of rowspecific weights used for selection bias
adjustment. The default is 
expected 
A logical value indicating whether or not to calculate the
covariance matrix via the expected Fisher information matrix. The default is 
tolerance 
A numeric value specifying when to stop estimation, based on
the difference of subsequent loglikelihood estimates. The default is 
max_em_iterations 
An integer specifying the maximum number of
iterations of the EM algorithm. The default is 
perfect_sensitivity_EM
returns a list containing nine elements.
The elements are detailed in ?SAMBA::obsloglikEM
documentation. Code
is adapted from the SAMBA::obsloglikEM
function.
Beesley, L. and Mukherjee, B. (2020). Statistical inference for association studies using electronic health records: Handling both selection bias and outcome misclassification. Biometrics, 78, 214226.