0

Consider a sequence of something like the following

\begin{minipage}[t]{0.49\textwidth}
\includegraphics[width=200pt]{figs/fig_12345_1.pdf}
\end{minipage}
\begin{minipage}[t]{0.49\textwidth}
\includegraphics[width=200pt]{figs/fig_12345_2.pdf}
\end{minipage}
\begin{minipage}[t]{0.49\textwidth}
\includegraphics[width=200pt]{figs/fig_12345_2.pdf}
\end{minipage}
...

The problem is that images are generated with R (actually the above code exists in .Rnw file) and in some cases an image is not generated. Hence in this place I'll have a square 200x200 telling that I'm trying to include a file that does not exist.

My idea is to generate blank 1x1 image when there's no data. Still it will not help because all minipages have fixed width. Can I make width of a minipage be dynamic? Maybe there's a better solution for my problem?

Thank you in advance!

Eugeny89
  • 165
  • 2
    Check here: https://tex.stackexchange.com/a/39983/120578 – koleygr Oct 03 '17 at 17:28
  • 1
    can't you detect from within R that there is no image and so not generate the latex code, rather than getting latex to check? Why do you have all the minipages? – David Carlisle Oct 03 '17 at 19:26

0 Answers0