View source: R/CreateOutliersPlot.R
CreateOutliersPlot | R Documentation |
This function will create, using the first components scores, a set of convex hulls of the scores based on 'bagplot' or 'KDE' methodology.
CreateOutliersPlot(fObj, optns = NULL, ...)
fObj |
A class object returned by FPCA() or FSVD(). |
optns |
A list of options control parameters specified by |
... |
Additional arguments for the 'plot' function. |
Available control options are
inflation ifactor for the bag-plot defining the loop of bag-plot or multiplying ifactor the KDE pilot bandwidth matrix. (see ?aplpack::compute.bagplot; ?ks::Hpi respectively; default: 2.58; 2 respectively).
string defining the outlier method used ('KDE', 'NN' or 'bagplot') (default: 'KDE')
logical specifying if the KDE estimate should be unimodal (default: FALSE, relevant only for variant='KDE')
logical specifying if during slicing we should used the directions of maximum variance (default: FALSE for FPCA, TRUE for FSVD)
integer between 3 and 16, denoting the number of slices to be used (default: 4, relevant only for groupingType='slice')
logical specifying if during slicing we should show the outline of the slice (default: FALSE)
character vector to be use as input in the 'colorRampPalette' function defining the outliers colours (default: c("red", "yellow", 'blue'), relevant only for groupingType='slice')
string specifying if a slice grouping ('slice') or a standard percentile/bagplot grouping ('standard') should be returned (default: 'standard')
a two-component vector with the index of the mode of variation to consider (default: c(1,2) for FPCA and c(1,1) for FSVD)
An (temporarily) invisible copy of a list containing the labels associated with each of sample curves.
P. J. Rousseeuw, I. Ruts, J. W. Tukey (1999): The bagplot: a bivariate boxplot, The American Statistician, vol. 53, no. 4, 382-387 R. J. Hyndman and H. L. Shang. (2010) Rainbow plots, bagplots, and boxplots for functional data, Journal of Computational and Graphical Statistics, 19(1), 29-45
set.seed(1)
n <- 420
pts <- seq(0, 1, by=0.05)
sampWiener <- Wiener(n, pts)
sampWiener <- Sparsify(sampWiener, pts, 10)
res <- FPCA(sampWiener$Ly, sampWiener$Lt,
list(dataType='Sparse', error=FALSE, kernel='epan', verbose=TRUE))
CreateOutliersPlot(res)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.