Placing graphics/images inside a table

By thurnherr

Pictures do not necessarily have to be placed inside the figure environment, but can perfectly be included inside table cells.

The advantage is, you can without any effort arrange a series of images in a matrix and individually scale them.

And here is how you would do it: You first need the graphicx package to include graphics:

\usepackage{graphicx}

Now you can directly start with your table environment and add graphics:

\begin{table}[ht]

\caption{A table arranging images}
\centering
\begin{tabular}{cc}
\includegraphics[scale=1]{graphic1}&\includegraphics[scale=1]{graphic2}\\
\newline
\includegraphics[scale=1]{graphic3}&\includegraphics[scale=1]{graphic4}\\
\end{tabular}
\label{tab:gt}

\end{table}%

Note: In order to have visual borders, you would have \hline instead of \newline and use horizontal bars in the column definition of the tabular environment (“|c|c|” instead of “cc”).

The downside of this technique is obvious, you do not have access to features provided by the figure environment like a label or caption. Nevertheless, it might still come in handy in certain situations.

Note: The figures will not appear in the \listoffigures index, for the reason mentioned above.

Tags: , , , , , ,

5 Responses to “Placing graphics/images inside a table”

  1. claudio Says:

    It’s cool and sample for covers et all. Tanks. cc

  2. Arsalan Says:

    Thanks a lot

  3. Juri Strumpflohner Says:

    Thanks, exactly what I was searching for.

  4. Shamima Says:

    Thanks a lot!!

  5. francisco Says:

    Thanks a lot!!!!! So easy and so cool

Leave a Reply