stableEM: Stable EM solution

Description Usage Arguments Details Value See Also Examples

Description

This function performs the clustering for different EM starting values in order to find a stable solution.

Usage

1
2
stableEM(x, K, numEMstart = 5, method = "separate", Sdist = "weibull", cutpoint = NULL,
EMoption = "classification", EMstop = 0.0001, maxiter = 1000, print.likvec = TRUE)

Arguments

x

Data frame or matrix of dimension n*p with survival times (NA's allowed).

K

Number of mixture components.

numEMstart

Number of different starting solutions

method

Imposing proportionality restrictions on the hazards: With separate no restrictions are imposed, main.g relates to a group main effect, main.p to the variables main effects. main.gp reflects the proportionality assumption over groups and variables. int.gp allows for interactions between groups and variables.

Sdist

Various survival distrubtions such as weibull, exponential, and rayleigh.

cutpoint

Integer value with upper bound for observed dwell times. Above this cutpoint, values are regarded as censored. If NULL, no censoring is performed

EMoption

classification is based on deterministic cluster assignment, maximization on deterministic assignment, and randomization provides a posterior-based randomized cluster assignement.

EMstop

Stopping criterion for EM-iteration.

maxiter

Maximum number of iterations.

print.likvec

If TRUE the likelihood values for different starting solutions are printed.

Details

After the computation of the models for different starting solutions using the function phmclust the best model is chosen, i.e., the model with the largest likelihood value. The output values refer to this final model.

Value

Returns an object of class mws with the following values:

K

Number of components

iter

Number of EM iterations

method

Method with propotionality restrictions used for estimation

Sdist

Assumed survival distribution

likelihood

Log-likelihood value for each iteration

pvisit

Matrix of prior probabilities due to NA structure

se.pvisit

Standard errors for priors

shape

Matrix with shape parameters

scale

Matrix with scale parameters

group

Final deterministic cluster assignment

posteriors

Final probabilistic cluster assignment

npar

Number of estimated parameters

aic

Akaike information criterion

bic

Bayes information criterion

clmean

Matrix with cluster means

se.clmean

Standard errors for cluster means

clmed

Matrix with cluster medians

See Also

phmclust,msBIC

Examples

1
2
3
4
5
## Exponental mixture model with 2 components for 4 different starting solutions
data(webshop)
res <- stableEM(webshop, K = 2, numEMstart = 4, Sdist = "exponential")
res
summary(res)

mixPHM documentation built on May 2, 2019, 5:56 p.m.