papaja icon indicating copy to clipboard operation
papaja copied to clipboard

apatable not knitting to word

Open kalifvaughn opened this issue 1 year ago • 3 comments

Hello there,

This is odd, as this was just working the other day, but now I cannot get my table to show up when knitting to Word. It does not matter if I reference the table in the text, or if I just call the table in an unnamed R chunk. It just does not appear.

It DOES appear if I knit to PDF, and it also appears if I use a default papaja template. But I am using the APA7 yaml header "hack" right now, and this is when it will not appear in Word.

Any thoughts or things I can try?

Thanks as always!

kalifvaughn avatar Jul 21 '22 19:07 kalifvaughn

Hard to say what might be happening without some code to look at. But you might be including something in the table which requires LaTeX for it to render.

Can you give us some code that will reproduce the problem? For example could you create a near identical table with the same columns and headers using mtcars which will cause the problem in a brand new apa6_docx rmd?

conig avatar Aug 01 '22 05:08 conig

Hi conig,

The issue is most certainly related to LaTeX. It is a big stats table full of t-test, ANOVA, and regression results.

Are all LaTeX tables not cooperating with Word right now? It worked for awhile but then stopped. I eventually just edited the prior version manually.

kalifvaughn avatar Aug 02 '22 17:08 kalifvaughn

The issue is that papaja::apa_table does not translate latex syntax to word elements. Pandoc does that and not everything can be translated (latex is huge and growing).

Without seeing your code, something you added to the table cannot be translated to docx by pandoc and so is preventing the table from being rendered.

You could try removing each latex element one at a time until you find the culprit. Let us know what you discover.

conig avatar Aug 04 '22 00:08 conig

Thanks for chiming in, James. Indeed, there is not much I can do to help without a minimal reproducible example.

crsh avatar Oct 27 '22 21:10 crsh

This issue has been automatically closed because there has been no response to our request for more information from the original author. With only the information that is currently in the issue, we don't have enough information to take action. Please reach out if you have or find the answers we need so that we can investigate further.

github-actions[bot] avatar Nov 25 '22 18:11 github-actions[bot]