Using apaTables or apaStyles packages with knitr

若如初见. 提交于 2019-12-08 08:03:45

问题


Problem

Social scientists format tables and documents with APA style. There are packages like stargazer and xtable (here is an extensive list) that provide clean table formatting for those using latex and knitr. However, these packages do not conform to APA style rules in all cases.

Building and formatting tables from scratch is time consuming. Fortunately, there are two R packages for creating tables and documents compliant with APA style guidelines: apaStyle and apaTables. Unfortunately, both packages only output to MS Word.

Questions

  • Is there a way to use APAStyle and APATables so that output is integrated into HTML or PDF output from a .Rmd file?
  • What other packages do you use to create APA style tables in your .Rmd file—especially when using knitr to create PDF files.

回答1:


Concerning your second question, check out apa_table() from Frederik Aust's package papaja. I found it incredibly helpful for reporting all output in APA style (not only tables).

  • These installation instructions and user guide helped me to get started.
  • However, to see how much you can actually do with papaja, I greatly benefitted from this openly accessible example paper.


来源:https://stackoverflow.com/questions/44267088/using-apatables-or-apastyles-packages-with-knitr

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!