zscore: Safe centering and scaling: it avoids dividing by 0

Description Usage Arguments Value

View source: R/standardization.R

Description

Safe centering and scaling: it avoids dividing by 0

Usage

1
zscore(x, center = TRUE, scale = TRUE)

Arguments

x

matrix to center and scale

center

either numeric vector or logical

scale

either numeric vector or logical. If numeric, the 0 entries are internally replaced by 1 to avoid dividing by zero.

Value

centred and scaled matrix


unoe/noe documentation built on Nov. 5, 2019, 11:05 a.m.