mphase1: Distribution-free Phase I analysis of multivariate data

View source: R/mphase1.R

mphase1R Documentation

Distribution-free Phase I analysis of multivariate data

Description

Retrospective change point detection using the method described by Capizzi and Masarotto (2017).

Usage

mphase1(x, plot = TRUE, post.signal = TRUE, isolated = dim(x)[2] > 1, step = TRUE,
        alpha = 0.05, gamma = 0.5, K = min(50, round(sqrt(dim(x)[3]))),
        lmin = 5, L = 1000, seed = 11642257)

Arguments

x

a pxnxm array containing the observations; x[r,j,i] is the jth observation on the rth variable of the ith subgroup.

plot

logical; if FALSE the diagnostic plot is not displayed.

post.signal

logical; if FALSE the diagnostic LASSO-based analysis is not performed.

isolated

logical; if FALSE isolated shifts are not detected.

step

logical; if FALSE step shifts are not detected.

alpha

real; the acceptable false alarm probability; if the observed p-value is greater than alpha, then the estimated mean function is a constant.

gamma

real; the extra penalization for the extended BIC criteria.

K

integer; the maximum number of shifts which the procedure tries to detect.

lmin

integer; the minimum length of a step shift.

L

integer; the number of random permutations used to compute the p-values.

seed

integer; if not NA, the RNG's state is re-setted using seed. The current .Random.seed will be preserved.

Value

Functions mphase1 returns an object of class mphase1 containing

p.value

The p-value.

Wobs

The overall test statistic.

alasso

A data-frame containing the result of the post-signal diagnosis analysis,i.e., the times and types of shifts and the involved variables identified using the adaptive LASSO.

forward

A data frame containing the result of the forward search analysis, i.e., the times and types of the possible shifts as well as the elementary test statistics and the estimates of their (conditional) means and standard deviations.

center, scatter

The location vector and dispersion matrix used to standardize the original data.

signed.ranks

A pxnxm array containing the signed ranks.

fitted, residuals

Two pxnxm arrays containing the fitted means and the residuals, i.e., the difference between the observations and the fitted values.

Author(s)

Giovanna Capizzi and Guido Masarotto.

References

G. Capizzi and G. Masarotto (2017), Phase I Distribution-Free Analysis of Multivariate Data, Technometrics, 59, pp. 484–495, \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1080/00401706.2016.1272494")}.

See Also

postsignal.

Examples

  # A simulated in-control data from a Student's t distribution
  # with 3 degrees of freedom
  set.seed(123)
  x <- sweep(array(rnorm(5*5*50),c(5,5,50)),c(2,3),sqrt(rchisq(5*50,3)/3),"/")
  mphase1(x)
  # Reproduction of the two examples given in Capizzi and Masarotto (2016)
  data(ryan)
  mphase1(ryan)
  data(gravel)
  mphase1(gravel)

dfphase1 documentation built on July 9, 2023, 7:29 p.m.