decomp.cov {SpatialTools} | R Documentation |
Calculates decomposition of covariance matrix
Description
Calculates a decomposition of the provided covariance matrix, V
, using the chosen method.
Usage
decomp.cov(V, method = "eigen")
Arguments
V |
A (symmetric, positive-definite) covariance matrix. |
method |
A character vector specifying the method used to decompose |
Details
The matrix V
is assumed to be symmetric and positive definite. Symmetry is checked, but the positive definiteness of the matrix is not. Returns a decomposition matrix U
such that V
= U
%*% t(U)
.
Value
Returns a decomposition matrix U
such that V
= U
%*% t(U)
.
Author(s)
Joshua French
See Also
cov.sp
Examples
data(toydata)
U <- decomp.cov(toydata$V, method = "chol")
#range(toydata$V - U %*% t(U))
[Package SpatialTools version 1.0.5 Index]