Learn R Programming

VBmix (version 0.3.2)

mvnradiusdensity:

Description

get densities of a set of squared radii, i.e. obtained from a Mahalanobis distance computed externally wrt an inverse covariance matrix.

Usage

mvnradiusdensity(cov, radii)

Arguments

cov
Covariance matrix from which we compute the determinant.
radii
Radii wrt which we directly take the density values.

Value

numeric vector containing densities.

See Also

mvngen mvndensity

Examples

Run this code
temp <- mvngen(c(0, 0), diag(2), 5)
R <- chol(solve(diag(2))) 
# trivial here, as Cholesky R of I(-1) is I
temp <- temp <!-- %*% t(R) %*% R %*% t(temp) -->
mvnradiusdensity(diag(2), diag(temp))

Run the code above in your browser using DataLab