OK, I've been staring at this for an hour. I know there's an error in this frame, as the document compiles fine if I put \end{document} in the frame before this. But this frame gives an error about extra } or missing endgroup.
Where is it?????
\begin{frame}[fragile]
\frametitle{PROC TEMPLATE for a fancy graph (part 1)}
\begin{alltt}
proc template;
define statgraph scatdens2;
begingraph; *BEGIN DEFINING THE GRAPH;
entrytitle "Scatter plot with density plots";
*CREATE A TITLE;
layout lattice/columns = 2 rows = 2
columnweights = (.8 .2) rowweights = (.8 .2)
columndatarange = union rowdatarange = union;
*LAYOUT LATTICE...SETS UP A GRID OF GRAPHS;
*COLUMNWEIGHTS AND ROWWEIGHTS SETS
THE RELATIVE SIZE OF THE INDIVIDUAL COLUMNS AND ROWS;
\end{alltt}
\end{frame}

\end{frame}(assuming that this is real and not an artefact from posting here) – Joseph Wright♦ May 9 '11 at 21:11