Description Usage Arguments Examples
Select the columns of interest and scale their rows. Scale function takes the default argument
center, scale
plus some additional, common with other function of the package. The output can
be either appended into the input dataframe or you can drop the input keeping only the scaled data.
1 2 |
x |
A dataframe with the values to be normalized. |
columns |
Vector containing column names to be standardized. By default all columns will be selected
|
complete_match |
Logical with default value |
center |
See |
scale |
See |
label |
Label tag to be added in each collumn. Default value is "nmax_". |
drop_input |
Select if you want to append the normalized data into the input dataframe or keep only them.
Logical with default value |
1 2 3 4 5 6 7 8 9 10 11 12 13 | df <- data.frame(text = c("A", "B", "C", "D", "E", "F", "G"),
V1 = c(1, 2, 3, 4, 3, 2, 1),
V2 = c(5, 6, 4, 3, NA, 6, 7),
V3 = c(3, 4, 5, 6, 7, 4, 3))
scaled_df <- scale_rows(x = df,
columns = c("V1", "V2", "V3"),
complete_match = TRUE,
drop_input = TRUE)
scaled_df <- scale_rows(x = df,
columns = "V",
complete_match = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.