gt Questions

2

Solved

How can I scale a table to fit a PDF page in Quarto? Example: --- title: "Untitled" format: pdf --- ```{r setup} #| include: false library(dplyr) library(gt) ``` ```{r tbl} #| include...
Vulpecula asked 16/10, 2022 at 19:21

1

I am creating a table using the gt package in R Studio, and I can't figure out a graceful way to make the columns more readable for tables with many rows. Take the following code: gt::sp500 %>% ...
Bestir asked 9/10, 2020 at 16:54

2

Solved

The code below library(magrittr) library(gt) library(dplyr) TestColumn_one <- c("CA", "FL", "GA", "MA", "NM", "OH", "OK", &...
rgt
Conception asked 29/10, 2020 at 0:26

1

Solved

I use the gt package to create and save a table that I produce. Recently, I have sometimes been getting the following error when I attempt to gtsave. Error in s$close() : attempt to apply non-funct...
rgt
Insociable asked 5/10, 2022 at 17:44

1

Sorry if this is a very trivial question but I've looked up and down the internet and can't find an answer. I'm making a basic table using the gt package in markdown. But I can't seem to get the te...
Misogamy asked 4/9, 2022 at 21:23

2

Solved

I would like to create a gt table where I display numeric values from two columns together in a single cell, but color the cells based on just one of the column's values. For example using the Toot...
rgt
Underpass asked 27/5, 2021 at 13:7

1

Solved

I'm trying to add a footnote to a row label of a gtsummary table, but I can't figure out how to reference the exact cell I want. Intended output Usint the default trial dataset, I'd like to add a f...
Depolarize asked 28/7, 2022 at 14:38

1

Solved

I am new to making revealjs slides using Quarto in R and RStudio. I would like to include a {gt} table (https://gt.rstudio.com/) on a slide with the default gt styling. But the issue I am running i...
Think asked 7/7, 2022 at 22:17

2

Solved

I am trying to group some rows/variables (both categorical and continuous) to help with the table readability in a large dataset. Here is the dummy dataset: library(gtsummary) library(tidyverse) li...
Demolish asked 11/1, 2021 at 10:50

0

I am using the gt package to make a table ad saving it as an .RTF. I'm using the function gt::gtsave() but the table saved looks very different from what is in my viewer or outputs to HTML. Lin: to...
rgt
Jacquenette asked 13/5, 2022 at 14:36

0

Much like this poster, I am trying to make a table in r where I am grouping by levels of a factor. I am happy to do this in gt or kabbleExtra or any other package which makes a graph like this poss...
Absolutely asked 29/4, 2022 at 12:44

2

Solved

I would like to use sparkline mini charts with gt's package table. Is it possible? I know it is possible with formattable, but I would prefer to use gt tables. Here is what I want to accomplish and...
Oquinn asked 22/10, 2020 at 9:29

5

I'm getting that error message when running library(gt) Help would be appreciated
rgt
Morn asked 5/9, 2021 at 23:24

2

Solved

This is my first post, so apologies if I messed something up. I am trying to apply conditional formatting to multiple columns (comparing results for samples SampA, SampB and SampB to Limit) of a gt...
rgt
Gabriel asked 26/4, 2020 at 2:17

3

Solved

I'm trying to figure out if there's a way to use for-loops to create multiple tables in one go, all using the same dataset - I'll clarify that in a second. I'm using R Markdown, because I need to c...
Baba asked 12/10, 2021 at 16:29

3

Solved

I'm using the {gt} package to create tables in a report. I would like it so that the "$0.00" currency values are replaced with "-", which is something that's easy to do in Excel...
rgt
Cutup asked 24/8, 2021 at 17:32

0

I am building a long table using gt, and I would like to know if there is a way to repeat the column labels on row group line. On the image of gt table, repeat the "COLUMN LABEL" on the ...
rgt
Micronesian asked 11/6, 2021 at 12:4

0

This is a very general question. I created a few tables in an R markdown using the gt package. I was wondering how to scale down the table so it fits into the PDF created when I knit the markdown s...
Peggie asked 26/5, 2021 at 0:17

0

Currently the gtsave function in the gt package does not support MS-Word. I tried converting a gt object to a flextable object to then save as word, but flextable doesn't support a gt object. And w...
rgt
Rozina asked 10/5, 2021 at 8:50

1

Solved

I am programming a report generator that export html. I use two files, the first is a loop that will determine the number of reports and within my .Rmd template I have another loop to print several...
Benghazi asked 26/3, 2021 at 7:51

1

Solved

I would like to take a gt() table and transform it to a "wide" format instead of a "long" format by group level. So for, as an example using the iris data set: library(dplyr) l...
Haleakala asked 5/2, 2021 at 22:11

2

Solved

I'm trying to replicate this process and get the gt package to render ggplot objects where each row in the table gets a different graph (like a spark line). There appears to be a solution on the l...
Lycanthropy asked 11/5, 2020 at 23:57

2

Solved

I'm trying to generate a neat table using the kableExtra / gt packages (or anything that works), with a goal of having my value columns grouped by the different Variables: data <- data.frame(Nam...
Septuor asked 9/1, 2021 at 11:33

2

Solved

If I want to efficiently format rows of a gt table, is there a better method than what I have shown below. Some rows are character, and so need no formatting, some are numbers where one decimal ...
Vento asked 12/6, 2020 at 5:39

2

Solved

I am looking for a way to create a conditional bar plot as part of a gt table (the wonderful grammar of tables package). It seems to be possible in DT's datatable as shown here styleColorBar Center...
Messy asked 20/10, 2020 at 10:4

© 2022 - 2024 — McMap. All rights reserved.