Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

The following beamer code

\begin{frame}[fragile]
\frametitle{PROC TEMPLATE for a fancy graph (part 2)}
\begin{alltt}
      rowaxes;
        rowaxis /label = 'Infant Mortality (\%)'
         griddisplay = on;
        rowaxis /label = '' griddisplay = on;
      endrowaxes;
    layout overlay; 
      scatterplot x = unemployment 
        y = infantmortality;
      loessplot x = unemployment
        y = infantmortality/nomarkers;
      loessplot x = unemployment
           y = infantmortality/smooth = 1;
      ellipse  x = unemployment y = infantmortality
             /type = predicted;
     endlayout;
\end{alltt}
\end{frame}

Indents as shown until the line starting "ellipse" which is set flush left. Adding a paragraph marker after "unemployment" does not help.

Any ideas?

share|improve this question

migrated from stackoverflow.com Sep 20 '11 at 1:09

This question came from our site for professional and enthusiast programmers.

2  
Your code snippet works OK for me, after suitable completion. Could you please post a (complete) minimal working example illustrating the problem? –  Gonzalo Medina Sep 20 '11 at 1:22
    
A cause for this can be using <tab> instead of spaces. –  egreg Sep 20 '11 at 12:15

1 Answer 1

up vote 2 down vote accepted

I cannot see any problem, when I create a complete document from your code fragment! However, beamer knows the environment semiverbatim which can also be used:

\documentclass{beamer}
\begin{document}

\begin{frame}[fragile]
\frametitle{PROC TEMPLATE for a fancy graph (part 2)}
\begin{semiverbatim}
      rowaxes;
        rowaxis /label = 'Infant Mortality (\%)'
         griddisplay = on;
        rowaxis /label = '' griddisplay = on;
      endrowaxes;
    layout overlay; 
      scatterplot x = unemployment 
        y = infantmortality;
      loessplot x = unemployment
        y = infantmortality/nomarkers;
      loessplot x = unemployment
           y = infantmortality/smooth = 1;
      ellipse  x = unemployment y = infantmortality
             /type = predicted;
     endlayout;
\end{semiverbatim}
\end{frame}

\end{document}

enter image description here

share|improve this answer
    
Thanks! semiverbatim solved this problem. I hadn't even heard of this environment. –  Peter Flom Sep 20 '11 at 10:59

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.