Description Usage Arguments Value
View source: R/latentclasslogit.R
This function performs maximum-likelihood estimation via the E-M algorithm to obtain estimates of regression coefficients in a latent class logistic regression model.
1 2 3 |
formula |
a regression formula describing the relationship between the response and the covariates |
data |
the data.frame containing the responses and covariates |
K |
the number of mixtures (or latent classes) |
start.beta |
a list of length K of starting values for each mixture's beta coefficients |
start.lambda |
a vector of length K of starting values for the mixing proportions |
id |
the (character) name of the column containing subject IDs |
tol |
a numeric tolerance used to determine convergence |
theta.lower |
a numeric vector of lower bounds for the theta parameters |
theta.upper |
a numeric vector of upper bounds for the theta parameters |
method |
a string specifying the optimization routine to be used by optim |
a list containing the following elements:
beta |
a list containing the estimated regression coefficients |
sigma |
a vector containing the estimated values of sigma |
lambda |
a vector containing the estimated mixing proportions |
delta |
a list of length K containing the estimated class membership probabilities for each observation |
ll |
the log-likelihood function evaluated at the MLE |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.