# Can I convert a 16 page pdf into an 8x2 matrix in LaTeX?

My graphing program (R) can plot a set of figures out, each on a separate page of the same pdf. Is there a way to convert this into a single 4x4 or 8x2 figure in LaTeX? There are alternatives, but this would be preferable.

-
This question seems related to tex.stackexchange.com/questions/7123/… –  xport Dec 29 '10 at 3:20
If you choose 8x2 then each pdf becomes so small and you will need a magnifying glass to read the printed version. I recommend you to use 2x1 or 1x2 or 2x2. More than this will be hard to read. –  xport Dec 29 '10 at 3:29
@xport in my case, each page is a simple xy plot, and I can adjust the dimensions and fonts as needed, I just need to be able to arrange them. –  David Dec 29 '10 at 5:44
@xport: 4x4 sounds very small, but we can't say anything useful about readability if we don't see an example plot. –  Charles Stewart Dec 29 '10 at 10:53
I'd like to see a Context solution to this. It should be possible using mplib. –  Charles Stewart Dec 29 '10 at 10:59

It is very easy. Please use pdfpages.sty and click here for its manual.

# Code Snippet Sample

I used a pdf file downloaded from here and then renamed it as movies.pdf.

\documentclass{article}
\usepackage[a4paper,margin=1cm]{geometry}
\usepackage{pdfpages}
\begin{document}
\includepdf[%
landscape=true,%
pages={1-16},%Include pages from 1 to 16.
nup=2x3,%If landscape=false then it defines columns x rows. Otherwise it defines rows by columns.
]{movies.pdf}%Pdf file name with or without extension.
\end{document}

-