Description Usage Arguments Value Examples
View source: R/utility_functions.R
This function centers and scales a variable, and adds attributes that allow the function to convert the standardized variable back into its original scale.
1 | standardize(x, reverse = F)
|
x |
a numerical value. |
reverse |
logical; if true, the function extracts the 'mean' and 'scale' attributes and reverses the standardization. |
If reverse is FALSE, returns the standardized values for x, with attributes giving the mean and scale; otherwise, returns the raw, unstandardized values of x.
1 2 3 4 5 6 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.