R/cent.R

Defines functions cent

Documented in cent

#' cent
#'
#' @param X vector to be centered
#'
#' @return Returns a centered vector
#' @export
#'
#' @examples X<-c(1:10)
#' cent(X)
cent<-function(X){
  X<-X-mean(X)
  return(X)
}

Try the Omisc package in your browser

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

Omisc documentation built on Aug. 9, 2022, 5:09 p.m.