one LaTeX source file to produce two different pdf files: one main manuscript and one Supplementary Materials
Christopher W. Ryan
cryan at binghamton.edu
Mon Jul 18 21:14:11 CEST 2022
I suppose this is a question at the intersection of LaTeX, R, Sweave. So
not entirely sure which listserve is the best place to post it.
For my statistical/academic work, I create a noweb .Rnw file and use an
R -> Sweave -> pdflatex workflow (incidentally using emacs and Emacs
Speaks Statistics as an IDE of sorts, but I think that is immaterial.)
Model-fitting produces many graphs. I generate these each as their own
pdf file, and then use
\begin{figure}
\includegraphics{}
\caption{}\label{}
\end{figure}
blocks to include them in the manuscript.
Some grpahs are for inclusion in a main manuscript, while others are
diagnostic plots assessing the adequacy of the model that probably
should be relegated at a separate pdf file of "Supplementary Materials".
Many journals accept/encourage such materials these days.
Is there a way to generate two pdf files, the main manuscript and the
Supplementary Materials, in one fell swoop (meaning compile the Rnw file
just once)? Or do I need to write a separate LaTeX source file that
includes the supplementary graphics and compile that separately? I
suspect the latter is true, and the former would be expecting too much
magic. But thought I'd ask.
Thanks.
--Chris Ryan
More information about the texhax
mailing list.