Description Usage Arguments Value Examples
Function standardizes numeric vector using multiple methods
1 | standardize(x, method = "zs", na.rm = FALSE)
|
x |
Numeric vector |
method |
Character string. Default is 'zs' (for z-score method). Other options include '01' (0 to 1 scaling) and 'pr' (percent rank) |
na.rm |
Should NAs be removed? Default is |
Numeric vector with standardized values
1 2 3 4 | x <- c(1, 4, 5, 6, 2, 4, 10, 12, 5)
standardize(x)
standardize(x, method = "01")
standardize(x, method = "pr")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.