One of my favorite ways to get summaries is to use
janitor::tabyl(), and using
map helps me get every variable (or all non-numeric like the following example). When I do one variable at a time (e.g.
df%>% tabyl(Variable) I can then pipe into
gt::gt %>%gtsave("name.tex"). But when I make my tabyl through
map, I can't. Any suggestions?
library(gt) library(janitor) library(datasets) gss_cat%>% select(!where(is.numeric)) %>% map(~(tabyl(.) %>% adorn_pct_formatting()))
PS. I've duplicated the question to SO on request from janitor's package author, I'll update any answer I get there, in case it happens first.