Description Usage Arguments Details Author(s) Examples
Computes the Tukey depth of a point or vectors of points with respect to a multivariate data set.
1 2 | depthTukey(u, X, ndir = 1000, seed = 1, name = "X", threads = -1,
exact = FALSE, ...)
|
u |
Numerical vector or matrix whose depth is to be calculated. Dimension has to be the same as that of the observations. |
X |
The data as a matrix, data frame or list. If it is a matrix or data frame, then each row is viewed as one multivariate observation. If it is a list, all components must be numerical vectors of equal length (coordinates of observations). |
ndir |
number of directions used in computations |
seed |
this seed is used in random number generator in C++ code. Value -1 means that seed is not set. |
threads |
number of threads used in parallel computations. Default value -1 means that all possible cores will be used. |
name |
name for this data set - it will be used on plots from depthproc. |
exact |
if TRUE exact alhorithm will be used . Currently it works only for 2 dimensional data set. |
... |
currently not supported. |
Irrespective of dimension, Projection and Tukey's depth is obtained by approximate calculation.
Returns the depth of multivariate point u
with respect to data set X
.
Daniel Kosiorowski, Mateusz Bocian, Anna Wegrzynkiewicz and Zygmunt Zawadzki from Cracow University of Economics.
1 2 3 4 5 6 | x <- matrix(rnorm(3000), nc = 3)
#Same results
depthTukey(x, x, ndir = 2000, seed = 1) == depthTukey(x, x, ndir = 2000, seed = 1)
#Different
depthTukey(x, x, ndir = 2000, seed = -1) == depthTukey(x, x, ndir = 2000, seed = -1)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.