Description Usage Arguments Details Value References See Also Examples
View source: R/depth.potential.r
Calculate the potential of the points w.r.t. a multivariate data set. The potential is the kernelestimated density multiplied by the prior probability of a class. Different from the data depths, a density estimate measures at a given point how much mass is located around it.
1 2 
x 
Matrix of objects (numerical vector as one object) whose depth is to be calculated; each row contains a dvariate point. Should have the same dimension as 
data 
Matrix of data where each row contains a dvariate point, w.r.t. which the depth is to be calculated. 
pretransform 
The method of data scaling.

kernel 

kernel.bandwidth 
the single bandwidth parameter of the kernel. If 
mah.parMcd 
is the value of the argument 
The potential is the kernelestimated density multiplied by the prior probability of a class. The kernel bandwidth matrix is decomposed into two parts, one of which describes the form of the data, and the other the width of the kernel. Then the first part is used to transform the data using the moments, while the second is employed as a parameter of the kernel and tuned to achieve the best separation. For details see Pokotylo and Mosler (2015).
Numerical vector of potentials, one for each row in x
; or one potential value if x
is a numerical vector.
Aizerman, M.A., Braverman, E.M., and Rozonoer, L.I. (1970). The Method of Potential Functions in the Theory of Machine Learning. Nauka (Moscow).
Pokotylo, O. and Mosler, K. (2015). Classification with the potpot plot. Mimeo.
depth.halfspace
for calculation of the Tukey depth.
depth.Mahalanobis
for calculation of Mahalanobis depth.
depth.projection
for calculation of projection depth.
depth.simplicial
for calculation of simplicial depth.
depth.simplicialVolume
for calculation of simplicial volume depth.
depth.spatial
for calculation of spatial depth.
depth.zonoid
for calculation of zonoid depth.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24  # 3dimensional normal distribution
data < mvrnorm(200, rep(0, 3),
matrix(c(1, 0, 0,
0, 2, 0,
0, 0, 1),
nrow = 3))
x < mvrnorm(10, rep(1, 3),
matrix(c(1, 0, 0,
0, 1, 0,
0, 0, 1),
nrow = 3))
# potential with rule of thumb bandwidth
pot < depth.potential(x, data)
cat("Potentials: ", pot, "\n")
# potential with bandwidth = 0.1
pot < depth.potential(x, data, kernel.bandwidth = 0.1)
cat("Potentials: ", pot, "\n")
# potential with robust MCD scaling
pot < depth.potential(x, data, kernel.bandwidth = 0.1,
pretransform = "NMCD", mah.parMcd = 0.6)
cat("Potentials: ", pot, "\n")

Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.