regmixMEMtestSeq: regmixMEMtestSeq

Description Usage Arguments Value Examples

Description

Sequentially performs MEM test given the data for y and x on the null hypothesis H_0: m = m_0 where m_0 is in 1, 2, ..., maxm; using this function is equivalent to calling normalmixMEMtestSeq with regressors specified by x as a parameter.

Usage

1
2
regmixMEMtestSeq(y, x, z = NULL, maxm = 3, ninits = 10, maxit = 2000,
  nbtsp = 199, parallel = 0, cl = NULL, crit.bootstrap.from = 3)

Arguments

y

n by 1 vector of data for y

x

n by q matrix of data for x

z

n by p matrix of regressor associated with gam

maxm

The maximum number of components set as null hypothesis in the mixture

ninits

The number of randomly drawn initial values.

maxit

The maximum number of iterations.

nbtsp

The number of bootstrap observations; by default, it is set to be 199

parallel

Determines whether package doParallel is used for calculation

cl

Cluster used for parallelization; if it is NULL, the system will automatically create a new one for computation accordingly.

crit.bootstrap.from

The minimum m in null hypothesis to have critical values calculated from bootstrap for the test statistics

Value

A list of with the following items:

alpha

maxm by maxm matrix, whose i-th column is a vector of alphas estimated given the null hypothesis m_0 = i

mu

maxm by maxm matrix, whose i-th column is a vector of mus estimated given the null hypothesis m_0 = i

sigma

maxm by maxm matrix, whose i-th column is a vector of sigmas estimated given the null hypothesis m_0 = i

beta

A list of length maxm, whose i-th element is a q times i matrix of betas estimated given the null hypothesis m_0 = i

gam

maxm by maxm matrix, whose i-th column is a vector of gams estimated given the null hypothesis m_0 = i

emstat

A maxm vector of values of modified EM statistics of the model at m_0 = 1, 2, ..., maxm

pvals

A maxm by 3 matrix whose i-th row indicates a vector of p-values at k = 1, 2, 3

aic

A maxm vector of Akaike Information Criterion of the fitted model at m_0 = 1, 2, ..., maxm

bic

A maxm vector of Bayesian Information Criterion of the fitted model at m_0 = 1, 2, ..., maxm

loglik

A maxm vector of log-likelihood values of the model at m_0 = 1, 2, ..., maxm

penloglik

A maxm vector of penalized log-likelihood values of the model at m_0 = 1, 2, ..., maxm

pmle.result

a list of output from regmixPMLE under the number of components selected by sequantial hypothesis testing

Examples

1
2
3
data(faithful)
attach(faithful)
## Not run: regmixMEMtestSeq(y = eruptions, x = waiting, parallel = 1)

hkasahar/normalregMix documentation built on May 17, 2019, 4 p.m.