42

Whenever I put

\begin{table}
\begin{tabular}
...
\end{tabular}
\caption{My great table}
\end{table}

It would end up with the name "Table 1: My great table". I don't want the prefix "Table 1:". Is there a way to suppress it?

1

2 Answers 2

47

I recommend you to use the \caption* command from the caption package:

\documentclass{article}
\usepackage{caption}
\begin{document}
\begin{table}
\begin{tabular}{ll}
1 & 2
\end{tabular}
\caption*{My great table}
\end{table}
\end{document}

As @egreg suggests there's also the possibility to do it using the \captionsetup command:

\documentclass{article}
\usepackage{caption}
\captionsetup{labelformat=empty}
\begin{document}
\begin{table}
\begin{tabular}{ll}
1 & 2
\end{tabular}
\caption{My great table}
\end{table}
\end{document}

Doing so you don't always need to use *.

The solution you're using depends on what you're trying to achieve. The second one adds your table to the list of tables whereas \caption* does not. (Thanks @Herbert)

6
  • 8
    You could also point out the possibility of setting labelformat=empty, that avoids the having to add *.
    – egreg
    Jan 22, 2012 at 10:27
  • 13
    \caption* and labelformat=empty are quite different in their behaviour! The latter will be in the table of contents and the first not
    – user2478
    Jan 22, 2012 at 10:36
  • Sorry for the necro, but when I tried to do this, LaTeX inserted a space between the caption and the table. Packages are amsmath, amsfonts, amssymb, booktabs, multirow. Table looks like this.
    – Rob Rose
    Feb 8, 2018 at 3:19
  • I'll have to second that. Same happened to my document. It's not hugely important for the thing I'm doing atm, but it does add a space, which might be unwanted in other cases. @egreg any ideas?
    – thymaro
    Apr 11, 2018 at 10:01
  • @thymaro I see no space. In order to verify it, I added <blank line>\centerline{My great table} before the \caption. The two text appear equally centered. Please, ask a new question with all details for reproducing the issue.
    – egreg
    Apr 11, 2018 at 10:10
1

If you are not interested to include it in either table of contents or list of tables, then simply add the title inside table environment as a normal text without using caption command

\documentclass{article}
\begin{document}
\begin{table}[h!]
    \centering
    Title above (as usual)
    \\
    \begin{tabular}{cc}
        1 & 2
    \end{tabular}
    \\
    Title below
\end{table}
\tableofcontents
\listoftables
\end{document}
2
  • Then, even the text of the caption would not appear in the table of contents. Nov 26, 2021 at 8:15
  • Yes It will not appear in either table of contents or list of tables Nov 26, 2021 at 10:43

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .