I created a Sweave file in RStudio, with mostly code:
\documentclass{article}
\begin{document}
Hello
<<>>=
library(x)
library(y)
library(z)
data(dataset)
plot(dataset$variable1, dataset$variable2)
[...] #This means "other lines", not literally written in my file
@
\end{document}
The PDF compilation went fine. Then I added more lines of code, but when I recompiled I got the error:
Error in (function (file = if (onefile) "Rplots.pdf" else "Rplot%3d.pdf,
In the Issues tab, it said the problem lies in opening the image file it created when I compiled the PDF for the first time. Any advice?