logistic2ph {sleev} | R Documentation |
Sieve maximum likelihood estimator (SMLE) for two-phase logistic regression problems
Description
This function returns the sieve maximum likelihood estimators (SMLE) for the logistic regression model from Lotspeich et al. (2021). See pacakge vigenette for code examples.
Usage
logistic2ph(
y_unval = NULL,
y = NULL,
x_unval = NULL,
x = NULL,
z = NULL,
data = NULL,
hn_scale = 1,
se = TRUE,
tol = 1e-04,
max_iter = 1000,
verbose = FALSE
)
Arguments
y_unval |
Column name of the error-prone or unvalidated binary outcome. This argument is optional. If |
y |
Column name that stores the validated value of |
x_unval |
Specifies the columns of the error-prone covariates. This argument is required. |
x |
Specifies the columns that store the validated values of |
z |
Specifies the columns of the accurately measured covariates. This argument is optional. |
data |
Specifies the name of the dataset. This argument is required. |
hn_scale |
Specifies the scale of the perturbation constant in the variance estimation. For example, if |
se |
If |
tol |
Specifies the convergence criterion in the EM algorithm. The default value is |
max_iter |
Maximum number of iterations in the EM algorithm. The default number is |
verbose |
If |
Details
Models for logistic2ph()
are specified through the arguments. The dataset input should at least contain columns for unvalidated error-prone outcome, validated error-prone outcome,
unvalidated error-prone covariate(s), validated error-prone covariate(s), and B-spline basis. B-spline basis can be generated from splines::bs()
function, with argument x
being the unvalidated error-prone covariate(s). See vignette for options in tuning the B-spline basis.
Value
logistic2ph()
returns an object of class "logistic2ph"
. The function coef()
is used to obtain the coefficients of the fitted model. The function summary()
is used to obtain and print a summary of results.
An object of class "logistic2ph"
is a list containing at least the following components:
call |
the matched call. |
coefficients |
A named vector of the logistic regression coefficient estimates. |
covariance |
The covariance matrix of the logistic regression coefficient estimates. |
converge |
In parameter estimation, if the EM algorithm converges, then |
converge_cov |
In variance estimation, if the EM algorithm converges, then |
References
Lotspeich, S. C., Shepherd, B. E., Amorim, G. G. C., Shaw, P. A., & Tao, R. (2021). Efficient odds ratio estimation under two-phase sampling using error-prone data from a multi-national HIV research cohort. Biometrics, biom.13512. https://doi.org/10.1111/biom.13512
Examples
## Not run:
# Regression model: ADE ~ CD4 + Prior_ART. ADE and CD4 are partially validated.
data("mock.vccc")
sn <- 20
data.logistic <- spline2ph(x = "CD4_unval", size = 20, degree = 3,
data = mock.vccc, group = "Prior_ART",
split_group = TRUE)
res_logistic <- logistic2ph(y = "ADE_val", y_unval = "ADE_unval",
x = "CD4_val", x_unval = "CD4_unval",
z = "Prior_ART", data = data.logistic,
hn_scale = 1/2, se = TRUE, tol = 1e-04,
max_iter = 1000, verbose = FALSE)
## End(Not run)