R/PCAeig.R

Defines functions `PCAeig`

`PCAeig` <-
    function(Y, scale = FALSE)
{
    Y <- scale(as.matrix(Y), center = TRUE, scale = scale)
    YY <- crossprod(Y)
    SOL <- eigen(YY, symmetric = TRUE)
    SOL$u <- Y %*% SOL$vectors %*% diag(1/sqrt(SOL$values))
    SOL
}

Try the barebone package in your browser

Any scripts or data that you put into this service are public.

barebone documentation built on May 2, 2019, 5:17 p.m.