what does scale do in r code example
Example: scale in r
set.seed(1)
x <- runif(7)
# Manually scaling
(x - mean(x)) / sd(x)
scale(x, center = TRUE, scale = TRUE)
set.seed(1)
x <- runif(7)
# Manually scaling
(x - mean(x)) / sd(x)
scale(x, center = TRUE, scale = TRUE)