comp_norm_test {ICSOutlier} | R Documentation |
Selection of Nonnormal Invariant Components Using Marginal Normality Tests
Description
Identifies invariant coordinates that are non normal using univariate normality tests.
Usage
comp_norm_test(
object,
test = "agostino.test",
type = "smallprop",
level = 0.05,
adjust = TRUE
)
Arguments
object |
object of class |
test |
name of the normality test to be used. Possibilites are |
type |
currently the only option is |
level |
the initial level used to make a decision based on the test p-values. See details. |
adjust |
logical. If |
Details
Currently the only available type
is "smallprop"
which detects which of the components follow a univariately normal distribution. It starts from the first component and stops when a component is detected as gaussian. Five tests for univariate normality are available. See normal_crit() function for more general cases.
If adjust = FALSE
all tests are performed at the same level
. This leads however often to too many components. Therefore some multiple testing adjustments might be useful. The current default adjusts the level for the jth component as level
/j.
Note that the function is seldomly called directly by the user but internally by ICS_outlier()
.
Value
A list containing:
-
index
: integer vector indicating the indices of the selected components. -
test
: string with the name of the normality test used. -
criterion
: vector of the p-values from the marginal normality tests for each component. -
levels
: vector of the levels used for the decision for each component. -
adjust
: logical.TRUE
if adjusted. -
type
:type
used
Author(s)
Aurore Archimbaud and Klaus Nordhausen
References
Archimbaud, A., Nordhausen, K. and Ruiz-Gazen, A. (2018), ICS for multivariate outlier detection with application to quality control. Computational Statistics & Data Analysis, 128:184-199. ISSN 0167-9473. doi:10.1016/j.csda.2018.06.011.
See Also
ICS(), comp_simu_test()
, jarque.test(),
anscombe.test(), bonett.test(), bonett.test(),
shapiro.test()
Examples
Z <- rmvnorm(1000, rep(0, 6))
# Add 20 outliers on the first component
Z[1:20, 1] <- Z[1:20, 1] + 10
pairs(Z)
icsZ <- ICS(Z)
# The shift located outliers can be displayed in one dimension
comp_norm_test(icsZ)
# Only one invariant component is non normal and selected.
comp_norm_test(icsZ, test = "bonett.test")
# Example with no outlier
Z0 <- rmvnorm(1000, rep(0, 6))
pairs(Z0)
icsZ0 <-ICS(Z0)
# Should select no component
comp_norm_test(icsZ0, level = 0.01)$index