[R] Page width figures in Latex

Sharpie chuck at sharpsteen.net
Mon Mar 29 05:21:54 CEST 2010



Jim Lemon wrote:
> 
> bRotheRs & sisteRs,
> I am once again attempting to learn enough Latex voodoo to get something 
> done, and failing comically. The document "RJAuthorguide.pdf"
> mentions that one can get page width figures through the use of the 
> "figure*" or "table* environments, but despite considerable searching 
> through the mail archives and reading Frank Harrell's discussion of 
> "Using Latex Figure Environments for Plots" until my eyes went on 
> strike, I am nowhere near a solution. Would anyone be kind enough to 
> point me to the Idiot's Guide to Latex Figure Environments?
> 
> Jim
> 

As far as I can recall, figure* and table* are used to create figures/tables
that span the entire page when the rest of the document is in twocolumn or
multicol mode.  I.e. these environments allow you to break out of a
multi-column layout to place a figure that acts like it was in a normal
single-column layout.

There are a bunch of caveats such as the figure/table will only appear at
the top or bottom of a page and will not appear on the same page as the
point at which it was declared in the source.  That is to say, when you
declare a figure* in a LaTeX document, one page break must pass before the
environment actually gets set in your document- no matter what !h or H vodoo
you pull.


If your document is not using multiple columns, then you may want to specify
the width of your figure when you place it using \includegraphics.  In order
to scale the figure so that it spans the entire page, set the width argument
equal to \textwidth:

\begin{figure}

  \centering
  \caption{A graph of x verses y along with a linear regression fit.}
  \label{fig:xVsY}

  \includegraphics[width=\textwidth]{/path/to/your/figure}

\end{figure}

Some good resources are:

The LaTeX Wikibook:

  http://en.wikibooks.org/wiki/LaTeX

Getting to Grips with LaTeX:

  http://www.andy-roberts.net/misc/latex/


Hope this helps!

-Charlie

-----
Charlie Sharpsteen
Undergraduate-- Environmental Resources Engineering
Humboldt State University
-- 
View this message in context: http://n4.nabble.com/Page-width-figures-in-Latex-tp1694612p1694673.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list