Graphics, Figures & TablesSeparating table label from table comment

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
renee74
Posts: 3
Joined: Sat Apr 03, 2010 7:55 am

Separating table label from table comment

Post by renee74 »

Hello,
I am trying to create a table that has the following structure.

Table 1
<Comment>
[Placement of actual Table]
Note

The only thing I can not figure out is how to separate the Table label from the comment. I keep getting the following format.

Table 1: <Comment>
[Placement of actual Table]
Note

Any suggestions would be helpful.
Thanks!

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

josephwright
Site Moderator
Posts: 814
Joined: Tue Jul 01, 2008 2:19 pm

Re: Separating table label from table comment

Post by josephwright »

Post your code so we can see what you are actually doing.
Joseph Wright
renee74
Posts: 3
Joined: Sat Apr 03, 2010 7:55 am

Re: Separating table label from table comment

Post by renee74 »

Here it is.

\begin{table*}[htdp]
\caption{Photochemical Lifetime and Vertical Mixing Time of Methane in Earth's Current Atmosphere}
\label{tab:tab1}
\begin{center}
\begin{tabular}{lcc} \thickline
Parameter & If released at 100 km & If released at 70 km \\ \hline
photochemical lifetime & 3-4 days & 8 months\\ \hline
vertical mixing & 1 month & 1 month \\ \hline
\end{tabular}
\end{center}
\tablefnt{\small Note. Values are adapted from `Aeronomy of the Middle Atmosphere' by G. Brasseur and S. Solomon, 1984).}
\end{table*}
User avatar
sommerfee
Posts: 503
Joined: Mon Apr 09, 2007 4:20 pm

Separating table label from table comment

Post by sommerfee »

Usage of the caption package is one possible solution:

Code: Select all

\documentclass{article}
\newcommand\tablefnt[1]{#1}
\newcommand\thickline{\hline}

\usepackage{caption}
\captionsetup[table]{singlelinecheck=off,labelsep=newline}

\begin{document}

\begin{table*}[htdp] 
\caption{Photochemical Lifetime and Vertical Mixing Time of Methane in Earth's Current Atmosphere}
\label{tab:tab1}
\begin{center}
\begin{tabular}{lcc} \thickline
Parameter & If released at 100 km & If released at 70 km \\ \hline
photochemical lifetime & 3-4 days & 8 months\\ \hline
vertical mixing & 1 month & 1 month \\ \hline 
\end{tabular}
\end{center}
\tablefnt{\small Note. Values are adapted from `Aeronomy of the Middle Atmosphere' by G. Brasseur and S. Solomon, 1984).}
\end{table*}

\end{document}
HTH,
Axel
renee74
Posts: 3
Joined: Sat Apr 03, 2010 7:55 am

Re: Separating table label from table comment

Post by renee74 »

Thank you!
That did work. I was using the caption package but did not know about the
\captionsetup[table]{singlelinecheck=off,labelsep=newline}
command.
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Re: Separating table label from table comment

Post by localghost »

It's always helpful to read the manual first. That's what it's made for.


Best regards and welcome to the board
Thorsten
Post Reply