library(dplyr) library(purrr)
\clearpage
Mostly working with this data; but some others come in later to illustrate certain features.
library(pmtables) library(yspec) spec <- ys_help$spec() data <- pmt_summarized data
There is a wrap function in this document. Don't worry about that; it just puts the output into a table environment and sends the output to get rendered in markdown.
\clearpage
data %>% stable(units = ys_get_unit(spec, parens = TRUE)) %>% st_asis()
\clearpage
data <- ptdata() data <- map_dfr(1:3, ~ data) %>% arrange(STUDY,DOSE,FORM)
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, units = ys_get_unit(spec, parens = TRUE), notes = "The results look great!", clear_reps = "DOSE", cols_rename = c(Formulation = "FORM"), r_file = "foo.R", output_file = "../deliv/table/output.tex", note_config = noteconf(type = "minipage", width = 0.8,table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "The results look great!", clear_reps = "DOSE", span = colgroup("A Group of Columns", N:SCR), cols_rename = c(Formulation = "FORM"), r_file = "foo.R", output_file = "../deliv/table/output.tex", note_config = noteconf(type = "minipage", width = 0.8,table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, units = ys_get_unit(spec, parens = TRUE), span = colgroup("A Group of Columns", N:SCR), notes = "The results look great!", clear_reps = "DOSE", cols_rename = c(Formulation = "FORM"), r_file = "foo.R", output_file = "../deliv/table/output.tex", note_config = noteconf(type = "minipage", width = 0.8,table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "The results look great!", clear_reps = "DOSE", lt_cap_text = "This is a super-interesting table.", note_config = noteconf(type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
- Then create the table with: ```{=latex} \newcommand{\myfbtable}{This is a caption from a macro}\vskip 0.5cm
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "FORM: formulation", r_file = "demo-longtable.Rmd", output_file = "foo.tex", clear_reps = "DOSE", lt_cap_macro = "myfbtable", note_config = noteconf(width = 0.7, type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "The results look great!", clear_reps = "DOSE", lt_cap_short = "a table", lt_cap_text = "This is a super-interesting table.", note_config = noteconf(type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "FORM: formulation", r_file = "demo-longtable.Rmd", output_file = "foo.tex", clear_reps = "DOSE", sizes = tab_size(row = 1), note_config = noteconf(width = 0.7, type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "FORM: formulation", r_file = "demo-longtable.Rmd", output_file = "foo.tex", clear_reps = "DOSE", sizes = tab_size(lt_row = 2), note_config = noteconf(width = 0.7, type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "FORM: formulation", r_file = "demo-longtable.Rmd", output_file = "foo.tex", clear_reps = "DOSE", note_config = noteconf(width = 0.7, type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
data %>% stable_long( panel = "STUDY", cols_bold = TRUE, notes = "FORM: formulation", r_file = "demo-longtable.Rmd", output_file = "foo.tex", clear_reps = "DOSE", sizes = tab_size(row = 1, col = 1), note_config = noteconf(width = 0.7, type = "minipage", table_skip = 0.1) ) %>% st_asis()
\clearpage
stable_long(stdata(), sizes = tab_size(font = "scriptsize")) %>% st_asis()
\clearpage
stable_long( data[1:10,], r_file = "foo.R", output_file = "foo.tex", notes = c("Data were analyzed in quadruplicate.", "The results are very clear."), ) %>% st_asis()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.