Description Usage Arguments Details Value Note Author(s) See Also Examples
This function uses a two-layer EM algorithm to fit a mixture model to progressive Type-II censored mixture data by estimating the latent mixture components and the censored data.
1 2 3 4 5 |
Pdat |
an object of class |
... |
additinal arguments to pass by. |
start |
a numeric vector; used as starting values for the EM algorithm. |
iteration |
the maximum number of required iteration for the EM algorithm until convergence– default value is 1e+05. |
INERiter |
the maximum number of required iteration for the second EM algorithm– default is 20. |
warn |
logical. shows warning messages if |
This function fits a two-component normal mixture model to a given progressive Type-II censored data.
It uses a two-layer EM algorithm for fitting the model. Generally speaking, the first layer estimates the mixture component latent variables, in the E-step, by finding their conditional expected values given the current parameter estimates and the data; and the second layer consists of another EM algorithm to estimate the missing censored data and eventually the parameters of interest. The layers are repeated until convergence achieved.
pcensmixR
gives an object of class data.frame
containing the following components:
muhat1,sigmahat1 |
component one parameter estimates (\hat{μ_1}, \hat{σ_1} ) |
muhat2,sigmahat2 |
component two parameter estimates (\hat{μ_2}, \hat{σ_2} ) |
pihat |
estimation of mixture proportion \hat{π} |
se.muhat1,se.sigmahat1 |
standard errors of \hat{μ_1} and \hat{σ_1} |
se.muhat2,se.sigmahat2 |
standard errors of \hat{μ_2} and \hat{σ_2} |
se.pihat |
standard error of \hat{π} |
no.fails.comp1,no.fails.comp2 |
number of failures from each mixture component |
no.cens.comp1,no.cens.comp2 |
number of censored observations from each mixture component |
ll |
log-likelihood value |
See pcgen
for the definition of censored
version of data.
Lida Fallah, John Hinde
Maintainer: Lida Fallah <l.fallah22@gmail.com>
1 2 3 4 5 6 7 8 9 10 11 | ## Example 1: fit a mixture model to 'insulate' data
set.seed(107)
Pdat<- pcgen(r = 15, p = 0.6, data = insulate)
pcensmixR(Pdat, start = c(5, 3, 35, 20, 0.6))
## Not run:
## Example 2: fit a mixture model to 'Systolic blood pressure' data
set.seed(1010)
pcensmixR(Pdat = pcgen(360, 0.35, blood$Systolic.BP),
start = c(120, 15, 150, 20, 0.6))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.