#' Standardize the input matrix
#'
#' @param X A matrix of any dimension
#' @return Returns a joint standardized matrix
#' @export
stdzjoint <- function(X){
Xbar <- apply(X, 2,mean)
invSd <- matpower(cov(X),-1/2)
Z <- t(invSd %*% (t(X) - Xbar))
return(Z)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.