Description Usage Arguments Value Examples
View source: R/write_bg_long.R
Make proportions of a list of factorial variables, and write it in excel all in one table
1 2 3 4 5 6 7 | write_bg_long(
x,
...,
folder_name = getwd(),
transpose = F,
name = "n_of_variables.xlsx"
)
|
x |
a tbl() that contains the variables of interest, keyed by ID variable |
... |
list of variables names that would appear in output |
folder_name |
where would the output file will be saved (project's home by default). |
transpose |
should it be horizontal (FALSE by default). |
name |
name of xlsx output file. |
computet tbl with the proportions of the variables of interest (as well as saved files)
1 2 3 4 5 6 7 8 9 10 11 12 | #example run
data=tribble(~ID,~car_size,~gender,
"1","large","woman",
"2","large","woman",
"3","small","woman",
"4","small","man",
"5","small","man",
"6","large","man",
"7",NA,"man")
long <- data %>%
write_bg_long(car_size,gender,folder_name = "R",transpose = F)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.