I'm trying to load images from a directory but I can't because I don't know why \i does not indicate the number, code searches the directory and the files were not found..
\documentclass{beamer}
\usepackage{pgfplots}
\usepackage{animate}
\begin{document}
\begin{frame}[label=detour]
\animate<1-3>
\begin{tikzpicture}
\begin{axis}[name=plot1,
clip=false,
axis lines=center,
height=4cm,
width=4cm,
x post scale=1.4,
]
\foreach \i in {1,...,3}{
\only<\i>{\addplot[blue, line width=0pt, fill=blue!20, opacity=0.5] table [col sep=tab,trim cells=true, x index=0, y index=\i] {images_thesis/resolution_images/espectros_im_P_10_F_0_sigma_500.txt}\closedcycle};
\only<\i>{\node[anchor=south west,inner sep=0] at (axis cs:20000,0) {\includegraphics[width=\textwidth]{./images_thesis/resolution_images/img-\i}};}}
\end{axis}
\end{tikzpicture}
\end{frame}
\end{document}
The error when pdflatex compiles is
File `./images_thesis/resolution_images/img-\i ' not found. \end{frame}
\onlypart? Or fast with the foreach and no tikzpicture – daleif Jul 31 '15 at 20:16{1,2,3}instead? – daleif Jul 31 '15 at 20:38But I can load only one image per frame, when I put another multiinclude, ERROR, and its so slow too...
– Alejandro Munoz Ossa Jul 31 '15 at 20:40\IfFileExists{filename with ext}{found}{not found}– daleif Jul 31 '15 at 20:56