Reputation: 119
I am trying out Knitr with RStudio. The output of plot() is now showing up in the compiled PDF.
Below is an example. The code shows up in the PDF, but not the plot.
\documentclass[11pt]{article}
\begin{document}
\SweaveOpts{concordance=TRUE}
<<my-label, eval=TRUE>>=
plot(1:20)
@
\end{document}
I'm not sure what I'm missing here?
Upvotes: 4
Views: 4406
Reputation: 3535
Your example doesn't work for me as is, but if I comment out \SweaveOpts{concordance=TRUE}
and click 'Compile PDF', it works (and I can see the plot).
(Note that I too am using Knitr with pdfLaTeX within RStudio.)
Upvotes: 2