0

When it comes to tables/figures, is it more common/standard/beneficial to put descriptions inside captions? I have separated descriptions from captions as follows, but I saw Use caption and long description for figure recently.

\documentclass{article}

\begin{document}

This is a sentence.

\begin{table}[h]
\caption{This is the title.}
\small The beginning description if needed.\par
{\centering\begin{tabular}{cccc} \hline
0.1234 & 0.5678 & 0.1234 & 0.5678 \\
0.1234 & 0.5678 & 0.1234 & 0.5678 \\ \hline
\end{tabular}\par}
The ending description if needed.
\end{table}

This is a sentence.

\begin{figure}[h]
\caption{This is the title.}
\small The beginning description if needed.\par
{\centering\rule{2in}{1.5in}\par}
The ending description if needed.
\end{figure}

This is a sentence.

\end{document}

As I have been studying LaTeX with no textbook, I even wonder whether the captions are in general located before/after the tables/figures. What is the best practice for writing the titles and the descriptions? Thanks.

Junyong Kim
  • 533
  • 4
  • 13
  • Usual convention: (Tables) Caption right before of the table. (Figures) Caption right after the figure. (Recommendation) Read a decent book about LaTeX :). – Dr. Manuel Kuehner Jun 28 '19 at 18:55
  • Some publications (IEEEtran) require using their own standard \caption (much to the dismay of many authors). – John Kormylo Jun 29 '19 at 15:29

1 Answers1

2

Usual convention:

  • (Tables) Caption right before of the table. Reason is (afaik), that a table can potentially span more than one page.
  • (Figures) Caption right after the figure.
  • The captions can be multi line -- no problem.
  • (Recommendation) Read a decent book about LaTeX :)

Additional information about the object (table or figure) is usually placed within the normal text and not within the environment (table or figure).


Basic Example

\documentclass{article}

\begin{document}

This is a sentence.

\begin{table}
\centering % optional
\caption{This is the title.}
\label{tab:TableID}
% Code for generating table.
\end{table}

This is a sentence that may include information regarding \tablename~\ref{tab:TableID}.

\begin{figure}
\centering % optional
% Code for generating figure, like \includegraphics[]{}.
\caption{This is the title.}
\label{fig:FigureID}
\end{figure}

This is a sentence that may include information regarding \figurename~\ref{fig:FigureID}.

\end{document}

More Advanced Example

Needs two LaTeX runs before the references are correct.

\documentclass{article}
\usepackage{graphicx}
\usepackage{float}

\begin{document}

This is a sentence.

\begin{table}[H] % H option from float package.
\centering % optional
\caption{This is the title.}
\label{tab:TableID}
% Code for generating table.
\includegraphics[width = 0.8\textwidth]{example-image} % See https://tex.stackexchange.com/questions/231738
\end{table}

This is a sentence that may include information regarding \tablename~\ref{tab:TableID}.

\begin{figure}[H] % H option from float package.
\centering % optional
% Code for generating figure, like \includegraphics[]{}.
\includegraphics[width = 0.8\textwidth]{example-image} % See https://tex.stackexchange.com/questions/231738
\caption{This is the title.}
\label{fig:FigureID}
\end{figure}

This is a sentence that may include information regarding \figurename~\ref{fig:FigureID}.

\end{document}

enter image description here

  • If I understood well, the OP asked also where to put some description after the captions. – CarLaTeX Jun 29 '19 at 08:58
  • @CarLaTeX Yes, there are two questions, the one that you mentioned and one regarding the position of the caption. I reply two both, but one of the questions I answer not directly (--> don't do it) :). So far the OP did not comment within 14 hours at all as you can see. Therefore I do not know if my answer is ok. – Dr. Manuel Kuehner Jun 29 '19 at 09:00
  • My apologies for this delayed response. I asked this banal question because I realized that I have exploited LaTeX as if it is a WYSIWYG device instead of a markup language (that is, thinking output first and then writing code) as I get accustomed to it. Studying LaTeX, I thought that its grammar was structured deliberately, although I have been unavoidably abusing it producing spaghetti code to tailor documents rather than understanding the philosophy considerately. The reason of the different caption practices of tables and figures seems apparent, but why is separating information preferred? – Junyong Kim Jun 30 '19 at 01:26
  • @JunyongKim Please elaborate your question. – Dr. Manuel Kuehner Jun 30 '19 at 06:13