Rotating, Non-Floating Figures in LaTeX

I’m working on a paper using the LaTeX typesetting system, and I’m loving it. However, I ran into a little challenge. I had a wide image that I wanted to put on its own page. By default LaTeX tries to be intelligent (and usually does a pretty good job of it) at placing graphics, using the floating approach. But in my document, it kept floating my graphic to a place I didn’t want it. Sometimes you just want to tell it exactly where to put the image and not allow it to float.

After a little searching, here’s how I went about it. Firstly, I made sure I had the following packages imported. If you haven’t downloaded them already, you’ll need to do that. In my case, I had a big enough hard drive that I had downloaded all packages when I installed LaTeX.

\usepackage{graphicx}
\usepackage{rotating}
\usepackage{float}
\usepackage{rotfloat}

Then in my document, I added a sideways figure like this:

\begin{sidewaysfigure}[H]
\includegraphics[width=8 in]{Figure.pdf}
\end{sidewaysfigure}

You can do something similar with a regular–not sideways–figure and with tables to keep things from floating.

\begin{figure}[H]
\includegraphics[width=8 in]{Figure.pdf}
\end{figure}

I won’t go into detail about how this all works. But you can find documentation for the different packages on the Web or in your LaTeX installation. Thanks to the developers who have created these helper packages.

Leave a Reply