Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

How do I prevent figures in the Appendix from appearing in the list of figures?

It seems that after the command \appendix the numbering automatically starts.

I've tried leaving the first part in the caption command blank like this:

\caption[ ]{First figure caption.}

but I still get a number in the List of Figures:

A.1 ........................23

I have also tried \captionsetup{list=no} which seems to have no effect at all. I want nothing in the list of figures for appendix material.

share|improve this question
4  
Hi Wes, Welcome to tex exchange! I edited your code by using the {} button to format the snippets. In regard to your question, if you load the caption package, then your approach should work fine. If not, please strip your code down to a MWE and include it in your question. –  cmhughes Mar 18 '12 at 21:13
    
Once you've loaded caption, you can also use caption*{} to completely suppress the numbering of a caption, which effectively also prevents it from appearing in the list of figures. This seems to be what you tried to achieve with \caption[ ]{the caption}. The solutions by @lockstep / @cmhughes however seem better-suited for your scenario and moreover can more easily be applied for all appendix captions. –  dgs Jun 3 '12 at 17:36
add comment

3 Answers

Set the tocdepth counter to 0 for the appendix. (See also the answers to Numbered section hidden from the ToC.)

Note that while I use the article class in the following MWE, the solution also works for classes featuring the \chapter command (notably, book and report) because figure and table floats always feature LoF/LoT level 1.

\documentclass{article}

\begin{document}

\listoffigures

\section{foo}

\begin{figure}[ht!]
\centering
\rule{1cm}{1cm}
\caption{A figure}
\end{figure}

\appendix 
\addtocontents{lof}{\protect\setcounter{tocdepth}{0}}

\section{bar}

\begin{figure}[ht!]
\centering
\rule{1cm}{1cm}
\caption{An appendix figure}
\end{figure}

\end{document}

enter image description here

EDIT: As cmhughes points out, an alternative is to load the caption package and to replace

\addtocontents{lof}{\protect\setcounter{tocdepth}{0}}

with

\captionsetup{list=no}

in the above example.

share|improve this answer
2  
Unfortunately \addtocontents{lof}{\protect\setcounter{tocdepth}{0}} somehow deletes the complete content of my listoftables (not just the tables in the appendix) while it works perfectly with the listoffigures. However \captionsetup{list=no} works just as expected. –  Rough Dude Sep 12 '12 at 9:25
    
The use of \addtocontents{lof}{\protect\setcounter{tocdepth}{0}} also breaks the index/bookmarks if outputting to pdf. Again, \captionsetup{list=no} works as desired. –  Hayden Apr 10 at 8:55
add comment

To prevent figures in the Appendix from appearing in the list of figures, you could simply comment out the line \label{This text appears in the List of Figures in front matter} which appears below the caption, by using %.

This includes the figure in the stipulated place, but does not make reference to it in the List of Figures. Good for grouping images (e.g. figure 3.1 a-f) which may be spread over multiple pages but only require one figure caption.

Similarly, captions can be commented out of tables in this way and will not be included in list of tables in front matter.

share|improve this answer
    
Welcome to TeX.SX! –  Claudio Fiandrino Nov 25 '13 at 15:01
add comment

I found \captionsetup{list=no} works great for suppressing figures, however, my sub-figures still appeared in the list of figures. This looked very odd to see list of subfloats with no main figure in the lof. The only solution I found was to change

\usepackage[lofdepth, lotdepth]{subfig}

to:

\usepackage[lofdepth=1, lotdepth]{subfig}

(as per another thread on removing subfigures from the lof.)

However, this removes all the subfigures in the document.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.