df_observed <- data_observed(
data = df_uc_om,
exposure = "X",
outcome = "Ystar",
confounders = "C1"
)
# Using validation data -----------------------------------------------------
df_validation <- data_validation(
data = df_uc_om_source,
true_exposure = "X",
true_outcome = "Y",
confounders = c("C1", "U"),
misclassified_outcome = "Ystar"
)
adjust_uc_om(
data_observed = df_observed,
data_validation = df_validation
)
# Using u_model_coefs and y_model_coefs -------------------------------------
adjust_uc_om(
data_observed = df_observed,
u_model_coefs = c(-0.22, 0.61, 0.70),
y_model_coefs = c(-2.85, 0.73, 1.60, 0.38)
)
# Using u1y0_model_coefs, u0y1_model_coefs, u1y1_model_coefs ----------------
adjust_uc_om(
data_observed = df_observed,
u1y0_model_coefs = c(-0.19, 0.61, 0.00, -0.07),
u0y1_model_coefs = c(-3.21, 0.60, 1.60, 0.36),
u1y1_model_coefs = c(-2.72, 1.24, 1.59, 0.34)
)
Run the code above in your browser using DataLab