Find the root matrix (x) from the Gram matrix (i.e., crossprod(x)).
This is also useful when the input is a covariance matrix, up to a scaling factor of n-1, where n is the sample size.
Usage
rootmatrix(x)
Arguments
x
a symmetric matrix (will trigger error if not symmetric).