# Preventing Export of PDF putting rows into columns

I have some graphics with two plots per row. When I Export as pdf all the plots are in a column. I want to keep them in rows. Here is a minimum working example.

 is = 5 72;
pp = Column[
Table[{
Row[{Plot[Sin[n t], {t, 0, 5 π}, ImageSize -> is,
PlotStyle -> Red],
Plot[Haversine[n t], {t, 0, 5 π}, ImageSize -> is,
PlotStyle -> Blue]}]
}, {n, 5}]
]


However following

Export["Fig.pdf", pp]


The pdf file has a plot that looks like

This seems to be an issue with the image size. If I reduce the value of is above to 4*72 then I get my two columns but this is too small. I have also tried

SetOptions["stdout", PageWidth -> Infinity]


but this does not work. Any suggestion for methods that keep my rows. (Note my actual case is more complicated). Thanks

• Works for me if I change Row to GraphicsRow. Apr 30 '19 at 21:01
• Or just use Grid
– M.R.
May 1 '19 at 18:14
• @MelaGo Thanks. This approach seems to put more space between my plots, but helps..
– Hugh
May 1 '19 at 18:31

Here are three ways to fix this:

is = 5 72;
pp = Column[
Table[Row[{Plot[Sin[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Red],
Plot[Haversine[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Blue]}], {n, 5}]];
pp1 = Grid[
Table[{Plot[Sin[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Red],
Plot[Haversine[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Blue]}, {n, 5}]];
pp2 = Column[
Table[GraphicsRow@{Plot[Sin[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Red],
Plot[Haversine[n t], {t, 0, 5 \[Pi]}, ImageSize -> is,
PlotStyle -> Blue]}, {n, 5}]];

GraphicsRow[{
Thumbnail@
First@Import@

• Thanks, I have some text which requires some aligning of plots. Grid and GraphicsRow upsets my layout. Your first solution works well in this case.