9

My question is along the lines of How do I ensure that figures appear in the section they're associated with?, but slightly different. I have a figure that occupies a full page. By default, LaTeX wants it to go on the very last page of the document. The previous question was answered with Rob Hyndman's suggestion of using a \FloatBarrier from the placeins package to demand that it appears before the start of a section. But if I do that, I get a pattern like this:

page (n-1): Section S of text ends halfway down the page.

page n: Full-page figure.

page (n+1): Section S+1 begins at the top of the page.

This is arguably better than having the figure at the end of the document, but it isn't the behavior I want. What I really want is the full-page figure in the middle, but Section S+1 beginning on page (n-1), so that the text flows normally from page (n-1) to page (n+1), with a page in the middle for the figure. Is there an easy way to achieve this?

The code looks something like this (\FIGURE comes from the JHEP3 class supplied by the Journal of High-Energy Physics, but I don't think this is sensitive to details of that file).

\FIGURE[!p]{
\begin{tabular}{cc}
\includegraphics[scale=0.5]{curve1.pdf}&
\includegraphics[scale=0.5]{curve2.pdf}\\
\includegraphics[scale=0.5]{curve3.pdf}&
\includegraphics[scale=0.5]{curve4.pdf}\\
\includegraphics[scale=0.5]{curve5.pdf}&\includegraphics[scale=0.5]{curve6.pdf}\\
\includegraphics[scale=0.5]{curve7.pdf}&\includegraphics[scale=0.5]{curve8.pdf}
\caption{Curves for case A (left), case B (right)}
\end{tabular}
\label{fig: constraints}}
  • 2
    We could probably do with an example. For instance did you try using the [p!] specifier? – Joseph Wright Aug 4 '10 at 19:03
  • I've tried !p, !h, and various other options. Details added; I don't know if they're helpful. – Matt Reece Aug 4 '10 at 19:15
8

The afterpage package might be useful here:

\usepackage{afterpage}
...
\section{S+1}
\afterpage{\clearpage}
% or \afterpage{\FloatBarrier}
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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