Skip to content

Commit

Permalink
Change float tables from h! to H (#171)
Browse files Browse the repository at this point in the history
  • Loading branch information
szimmer authored Aug 24, 2024
1 parent 1630dc7 commit b1725b9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ library(prettyunits)
book_colors <- c("#0b3954", "#087e8b", "#bfd7ea", "#ff8484", "#8d6b94")
as_latex_with_caption <- function(gtobj, chunk_label) {
lt <- nrow(gtobj[["_data"]]) >= 10
gt_l <- gtobj %>% tab_options(latex.use_longtable=lt, latex.tbl.pos="!htb") %>% gt::as_latex()
lt <- nrow(gtobj[["_data"]]) >= 5
gt_l <- gtobj %>% tab_options(latex.use_longtable=lt, latex.tbl.pos="H") %>% gt::as_latex()
caption <- paste0(
"\\caption{\\label{tab:", chunk_label, "}(ref:", chunk_label, ")}")
if (lt){
Expand Down

0 comments on commit b1725b9

Please sign in to comment.