Skip to content

Instantly share code, notes, and snippets.

@rpietro
Forked from JJ/Submitting Rmd to Arxiv.md
Created October 22, 2019 14:59
Show Gist options
  • Save rpietro/f3b9232dd860935efa70631a709531c1 to your computer and use it in GitHub Desktop.
Save rpietro/f3b9232dd860935efa70631a709531c1 to your computer and use it in GitHub Desktop.
Submitting RMarkdown articles to Arxiv

Mini-HowTo submit RMarkdown articles to ArXiV

ArXiV is a place for publishing scientific technical reports and drafts which is tightly tied to LaTeX. That is why if you generate a PDF from your RMarkdown article it will tell you, hey, this has been generated using LaTeX, I want the LaTeX source. In principle, RStudio does not admit LaTeX as a final format, only .doc, .pdf or HTML. But it is no big deal.

You only need to add this to the metadata in the RMarkdown document

output: 
  pdf_document:
    keep_tex: true

This will generate the intermediate files that are actually used to generate the PDF. You need only go to the directory where your .Rmd file is, gather the .tex and image directory (called filename_files) with

tar cvfz filename.tgz filename.tex filename_files

and submit it to ArXiV.

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