Skip to content

failed to make tables by "table1" and "gtsummary" packages in quarto book project  #1284

Closed

Description

@zawkzaw

Bug description

When I created a Quarto book in "docx" format with a chapter with codes from "table1" and "gtsummary" packages to construct summary tables, I failed to make it and saw the following error messages.

Error in flextable_to_rmd(x, bookdown = is_bookdown, pandoc2 = pandoc2, :
pandoc version >= 2.0 required for flextable rendering in docx
Calls: .main ... knit_print -> knit_print.flextable -> flextable_to_rmd
Execution halted

But when I created, using Rmd file, not qmd file as in quarto book, a separate word document with codes from "table1" and "gtsummary" packages to construct summary tables, I make it successfully.

How can I solve the problem in quarto qmd system?

Thanks

Ko Ko Zaw

Checklist

  • formatted your issue so it is easier for us to read?
  • included a minimal, self-contained, and reproducible example?
  • documented the quarto version you're running, by providing the output produced by quarto check in a terminal in your issue?
  • documented the RStudio IDE version you're running (if applicable), by providing the value displayed in the "About RStudio" main menu dialog?
  • documented which operating system you're running? If on Linux, please provide the specific distribution as well.
  • upgraded to the latest version, including your versions of R, the RStudio IDE, and relevant R packages?

Activity

  1. added
    bug
    on Jul 5, 2022
  2. added this to the Future milestone on Jul 5, 2022
  3. cderv commented on Jul 6, 2022

    @cderv
    Member

    With the information you provided, it could come from gtsummary or flextable package not supporting correctly being run inside Quarto instead of rmarkdown. The error you get means Pandoc version is not correctly detected and make flextable error.

    To check that further, we need a reproducible example. Can you share a one ? thanks

  4. zawkzaw commented on Jul 7, 2022

    @zawkzaw
    Author

    Thank you for your response. Fortunately, I was able to produce "gtsummary" and "table1" tables in docx file by quarto book project after I have reinstalled a recent quarto version 0.9.653.

    Best wishes

  5. cderv commented on Jul 7, 2022

    @cderv
    Member

    Good to know ! Thanks for the update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions