Several subfigures in a row. Latex only put 2 in a row. subfloat error

3.6k views Asked by At

i´m trying to align several subfigures in a row. 2 figures are working fine. When trying to include the third subfigure following err message appears: File ended while scanning use of @subfloat. \include{doc}

This tex document is included in the main file with packages:

\usepackage{graphicx}
\usepackage{subfigure}
\usepackage{subcaption}


%%%%%%new doc
\begin{figure}[h!]
\centering
\subfigure[a]{\includegraphics[width=0.1\textwidth]{Logos/Symbol_One_flow_path}}
\subfigure[b]{\includegraphics[width=0.1\textwidth]{Logos/1920px-Symbol_Two_flow_paths}}
\subfigure[c]{\includegraphics[width=0.1\textwidth]{Logos/Symbol_Two_flow_paths_(diagonally)} \subfigure[d]{\includegraphics[width=0.3\textwidth{Logos/Symbol_Two_flow_paths_with_connection}   
\subfigure[e]{\includegraphics[width=0.3\textwidth]{Logos/graph}    
\end{figure}
1

There are 1 answers

0
Maxime Etiévant On BEST ANSWER

this issue is probably due to the missing } at the end of figures c,d and e. That can explain why you just have the figures a and b.

\usepackage{graphicx}
\usepackage{subfigure}
\usepackage{subcaption}

\begin{figure}[h!]
\centering
\subfigure[a]{\includegraphics[width=0.1\textwidth]{Logos/Symbol_One_flow_path}}
\subfigure[b]{\includegraphics[width=0.1\textwidth]{Logos/1920px-Symbol_Two_flow_paths}}
\subfigure[c]{\includegraphics[width=0.1\textwidth]{Logos/Symbol_Two_flow_paths_(diagonally)}} %one } was missing here !
\subfigure[d]{\includegraphics[width=0.3\textwidth{Logos/Symbol_Two_flow_paths_with_connection}} % here also
\subfigure[e]{\includegraphics[width=0.3\textwidth]{Logos/graph}} %and here 
\end{figure}