GeneralDisplaying N= in table caption but not in list of tables

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
pjmiller_57
Posts: 20
Joined: Tue Nov 08, 2011 4:37 pm

Displaying N= in table caption but not in list of tables

Post by pjmiller_57 »

Hello All,

I have a question that may be simple to answer. I can't find anything about it in my LaTeX books though and didn't seem to find much online.

I'm creating a list of tables using:

\listoftables

I also have some table captions that contain the number of patients in an analysis like:

Code: Select all

\caption{Results for Random Forest Model Using Scoring Data (N = 700)}
The tables look great. Trouble is that LaTeX inserts the "(N = 700)" into the text in the List of Tables at the beginning of the document. I'd prefer that it not do so.

Is there some simple way to fix this?

Thanks,

Paul
Last edited by cgnieder on Mon Aug 20, 2012 10:36 pm, edited 1 time in total.

Recommended reading 2024:

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

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

cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

Displaying N= in table caption but not in list of tables

Post by cgnieder »

Use the optional argument of \caption:

Code: Select all

\caption[<use in LoF/LoT>]{<use with actual figure/table>}
Regards
site moderator & package author
pjmiller_57
Posts: 20
Joined: Tue Nov 08, 2011 4:37 pm

Re: Displaying N= in table caption but not in list of tables

Post by pjmiller_57 »

Thanks Clemens! Appreciate your help.

Paul
Post Reply