Round and format specified numeric columns in a data frame to a fixed number of decimal places.
data_round(data, cols, digits)
The input data frame, with the specified numeric columns rounded and formatted as character vectors.
A data frame or tibble.
A tidyselect expression specifying which columns to round
(e.g., c(var1, var2)
or starts_with("score")
).
Integer; number of decimal places to round.
For each selected numeric column: