I found this question about changing the size of a ggplot2 plot in Sweave. I added the Sweaveopts{width=3, height=3}
and it does shrink the size of the plot, but it doesn't scale down the text. So in the end, all of the numbers on the axes overlap.
Is there a way to scale the entire ggplot2 plot in Sweave so that I don't have to manually scale every component in the original ggplot2 call? It seems like something I should be able to do, but I can't find it in the ggplot2 book or on the website. Thanks!
FWIW, here's my call in Sweave:
\SweaveOpts{width=3, height=3}
\begin{figure}
\begin{center}
<<fig=TRUE>>=
print(plot.m)
@
\end{center}
\caption{stuff}
\label{fig:stuff}
\end{figure}
And the call that generates the ggplot2 plot:
plot.m <- ggplot(temp, aes(date, spread)) + geom_bar(stat="identity") + scale_x_date(major="years", minor="months")