I would like each frame
in a beamer
presentation to show a small table + 4 images
.
For every new frame, the 4 images change. On the contrary, only the content of one cell is changing in the table.
Given a list of FOLDERS
:
FOLDERS="
10.00K
30.10K
50.20K
70.30K
90.40K
"
I would need to loop over the elements of the FOLDERS
array so that the following could work, i.e.:
FOLDERS="
10.00K
30.10K
50.20K
70.30K
90.40K
"
for i in {FOLDERS}: %%%% LOOPING OVER THE i ELEMENTS OF THE ARRAY
\begin{frame}
\vspace{-0.5em}
\begin{table} % This is the small table I was referring to:
\centering
\begin{tabular}{c|c|c|c|c}
$E$ \text{ from \texttt{ABC}}&
$V$ &
$Z= -\frac{\partial M}{\partial N}$ &
$K = L + HJ$ &
$LK^{I}$ and $LL^{II}$ \\\hline
$\cdots$ &
$\cdots$ &
$\cdots$ &
$\cdots$ &
at {i} %%%% NOTE THAT HERE COMES i, THE ELEMENT FROM THE ARRAY
\end{tabular}
\end{table}
\vspace{-0.5em}
%
% This is the set of 4 images:
\makebox[\textwidth]{%
\begin{minipage}{1.05\textwidth} %
\includegraphics[width=.49\textwidth,keepaspectratio]
{/path/to/images/folder/{i}/myimage.pdf}% %%%% NOTE i HERE
\includegraphics[width=.49\textwidth,keepaspectratio]
{/path/to/images/folder/{i}/otherimage.pdf}\\[4pt] %%%% NOTE i HERE
\includegraphics[width=.49\textwidth,keepaspectratio]
{/path/to/images/folder/{i}/otherotherimage.pdf}\hfill% %%%% NOTE i HERE
\includegraphics[width=.49\textwidth,keepaspectratio]
{/path/to/images/folder/{i}/otherotherotherimage.pdf} %%%% NOTE i HERE
\end{minipage}
}
\end{frame}
Based on @marmot answer:
Both:
\begin{frame}
\foreach \X [count=\Y]in {10.00K, 30.10K}
{
\only<\Y>{
\makebox[\textwidth]{%
\begin{minipage}{1.05\textwidth} % <--- can be as large the slide size permits
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/image.pdf}}%
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_image.pdf}\\[4pt]
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_other_image.pdf}\hfill%
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_other_other_image.pdf}
}
\end{minipage}
\pause
}
\end{frame}
and:
\begin{frame}
\makebox[\textwidth]{%
\begin{minipage}{1.05\textwidth} %
\foreach \X [count=\Y]in {10.00K, 30.10K}
{
\only<\Y>{
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/image.pdf}}%
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_image.pdf}\\[4pt]
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_other_image.pdf}\hfill%
\includegraphics[width=.49\textwidth,keepaspectratio]{/path/to/\X/other_other_other_image.pdf}
\end{minipage}
\pause
}
}
\end{frame}
do not work.