{floats} is about the floating environments figure, table and other, custom-defined floats, and concerns issues such as positioning, labelling, captioning, indexing and listing of said floats. For questions specifically about formatting a float caption, consider using {captions}.

learn more… | top users | synonyms (2)

251
votes
2answers
67k views

How to influence the position of float environments like figure and table in LaTeX?

How to influence the position of float environments like figure and table in LaTeX? This is a general question and should collect useful answers for all users. I hope we can use this as a reference
149
votes
1answer
28k views

Should I use center or centering for figures and tables?

What is the correct way to center figures and tables (figure, table)? \begin{center} ... \end{center} or \begin{centering} ... \end{centering}
135
votes
2answers
229k views

Force figure placement in text

I have a problem when a lot of figures are in question. Some figures tend to "fly around", that is, be a paragraph below, although I placed them before that paragraph. I use code: \begin{figure}[ht] ...
132
votes
9answers
81k views

Keeping tables/figures close to where they are mentioned

Is there any package or a method to force LaTeX to keep floating environments like table and figure closer to where they are declared?
86
votes
2answers
29k views

Continuous v. per-chapter/section numbering of figures, tables, and other document elements

Some document elements (e.g., figures in the book class) are numbered per chapter (figure 1.1, 1.2, 2.1, ...). How can I achieve continuous numbering (figure 1, 2, 3, ...)? And vice versa: Some ...
74
votes
2answers
15k views

How do I ensure that figures appear in the section they're associated with?

Often floats may land quite a bit later in the document than the point they are created, sometimes after a section break. Is there a way to force a new section to start on a new page, after any ...
74
votes
1answer
5k views

How to include a picture over two pages, left part on left side, right on right (for books)?

When writing a long book (from 300 to over a 1000 pages), there is often need to include large pictures and one wishes to have them displayed over two pages, left half on the left page, right half on ...
73
votes
10answers
54k views

Using \footnote in a figure's \caption

Maybe this is an easy one, but I struggled with this now too long :) I want to have a footnote in a caption of a figure, see the example. \begin{figure}[!ht] \caption{a figure ...
69
votes
3answers
24k views

subcaption vs. subfig: Best package for referencing a subfigure

On this question a comment by Martin H says, that one should forget about the subfigure and subfig packages and use subcaption. As subfig replaces subfigure, no argument there. I am currently using ...
62
votes
3answers
21k views

Center figure that is wider than \textwidth

I have a figure that is wider than the \textwidth of my document. (I don't want to change the \textwidth.) As a result, the leftmost part of the figure is flush with the left margin, while the ...
57
votes
7answers
40k views

Custom margin settings for figure in LaTeX

I have a fairly large figure in a LaTeX document. This figure is too large for the left and right margin of the document. This results in the figure being placed flush with the left margin, and way ...
56
votes
4answers
21k views

Why should a table caption be placed above the table?

In the papers I read the caption in figure floats is placed below the figure and in table floats the caption is placed above the table. I recognize that this is a common style that a lot of people ...
48
votes
2answers
59k views

Changing the font size in a table

What's the recommend way of changing the font size in a particular table? Is there a better way than enclosing all values with, for example, the \tiny function.
48
votes
1answer
1k views

Unusual graphics and caption placement

Here is a picture from an Oxford University Press publication, showing two images a small one at the left and a larger one at the right. The unusual part is that the caption of the right image is also ...
44
votes
4answers
214k views

LaTeX figures side by side [duplicate]

Possible Duplicate: Caption issue when placing figure side by side I want to place 2 images side by side in LaTeX. I have 2 .png files and I don't understand how to do it in LaTeX. I have ...
43
votes
1answer
54k views

Why is \newpage ignored sometimes ?

I have the following towards the end of an article. The bibliography is short (4 entries). What's happening is that on the very last page of document I get the chart and immediately afterwards the ...
41
votes
3answers
15k views

What is the correct way to center a \tikzpicture? [duplicate]

Possible Duplicate: Should I use center or centering for figures and tables? What is the correct way to cause a \tikzpicture to be centered? By default it appears to be aligned with the ...
40
votes
2answers
17k views

Too many unprocessed floats

I'm trying to a large number of figures. The code is \begin{figure} \includegraphics[scale=0.5]{m2T4.pdf} \caption{M2T, Problem Size 513} \end{figure} I'm not able to compile, I get the error ! ...
36
votes
2answers
36k views

Change caption name of figures

How can I modify the caption name of a figure? For example I have \caption{This is a figure.} and by default the caption appears as Figure 1: This is a figure. However I want Fig.1 - This ...
36
votes
2answers
56k views

What does [t] and [ht] mean?

I would appreciate if someone could tell me difference between [t] and [ht] in the following example? I don't see a difference in the output pdf file. \begin{figure}[ht] ... \end{figure} and ...
35
votes
4answers
66k views

Force LaTeX image to appear in the section in which it's declared [duplicate]

Possible Duplicates: How do I ensure that figures appear in the section they're associated with? Keeping tables/figures close to where they are mentioned How can I force an image in a ...
34
votes
1answer
16k views

How to make a figure span on two columns in a scientific paper?

If I just try to set the figure's size to 0.9\textwidth my figure will just end up on the right column, sized to be two-columns wide. Has anyone done this before?
32
votes
1answer
22k views

How to change the spacing between figures/tables and text?

I was wondering if there is any way to lessen the spaces between figures and text. In my paper I have a lot of figures (graphics) and it is inconvenient for me to have default (large) spaces between ...
32
votes
4answers
26k views

How can I get the figures not to be pushed to the end of the document?

For some reason, my figures get pushed to the end of the document. I tried begin{figure}[t], [h] and other options, but none helped. Any ideas how to get the figures to appear much earlier in the ...
31
votes
2answers
10k views

Clearpage without pagebreak?

Is there a command which does the same like \clearpage (typesetting all floats which have not been typeset yet) but then does not insert a pagebreak but continues with the following text/graphics on ...
30
votes
2answers
35k views

Table and figure side-by-side with independent captions

Looking to put a table and a figure side by side so that the table and figure have their own captions. A crude sketch ------------ ----------------- TABLE | a | b | ...
30
votes
4answers
15k views

Two figures side by side [duplicate]

How can I put two figures side-by-side? Not two sub-figures, but two actual figures with separate "Fig.: bla bla" captions. A figure is supposed to spread over the entire text width, but I have two ...
28
votes
4answers
530 views

Where do I place floats in the source?

I realize that this is an embarrassing simple question. Shall I put the floats, e.g. \begin{figure} . . \end{figure} in the source immediately after first reference? or wait until the end of the ...
28
votes
4answers
36k views

Placing figures inside a two-column document

I'm trying to get images in my document in two different ways: On top of the entire page, centered On top of a single column I tried it with both twocols and multicols. I ruled out twocols because ...
27
votes
2answers
64k views

How to use figure inside a minipage?

I'm trying to include an image, and keep it centered, and prevent from wrapping from the next page. The following code works for that: \begin{minipage}{\textwidth} \begin{center} Caption ...
27
votes
1answer
10k views

Captions for figures in \listoffigures

When I use \listoftables and \listoffigures I get in the list long captions that appear next to the tables/figures. I would like to use short captions for this list which summarize these captions. Is ...
27
votes
2answers
10k views

What is the difference between \subfigure and \subfloat?

I've been just reading through this Latex wikibook and I spotted they advocate use of \subfloat in figures. I've always used \subfigure. What is the difference?
26
votes
1answer
24k views

`h' float specifier changed to `ht' warning when not attempting to specify a float

I'm new to LaTeX and trying to understand the reason why I'm getting the warning: `h' float specifier changed to `ht' I'm not attempting to change the float property of anything - the warning is ...
26
votes
2answers
16k views

multicol and figures

I have a two column document (using multicol) and want to insert figures so that they do NOT span columns. I have searched around and the only thing I can find says that only figure* is supported ...
25
votes
3answers
49k views

How to use the placement options [t], [h] with figures? [duplicate]

I want to control the placement of figures. The paper that I am currently writing contains a lot of figures, resulting in some figures ending up in the bibliography section. Therefore I want to ...
25
votes
3answers
3k views

Tables below footnotes, is this a good output routine algorithm or a bug?

Consider the minimal code below, which produces two different layouts depending on the table position marks. The first layout uses \begin{table} which results in the table ending below the ...
24
votes
1answer
15k views

How can I modify vertical space between figure and caption?

\documentclass{article} \usepackage[draft]{graphicx} \begin{document} \begin{figure} \centering \setlength\fboxsep{124pt} \setlength\fboxrule{1pt} \fbox{\includegraphics{dummy}} \caption{Dummy ...
24
votes
2answers
15k views

subfigure and subfig packages deprecated

I was using the subfigure package to align multiple small images in a document. However, WikiBooks states that "the subfigure and subfig packages are deprecated and shouldn't be used any more" ...
23
votes
2answers
810 views

Add a rule underneath “Figure 1”

I want to add a line beneath the figure caption such as Figure 1 Figure caption text here.... I managed to include a newline, change the color and look of the caption via caption package: ...
22
votes
5answers
13k views

How can I automatically center an image?

I use: \documentclss{mwrep} ... \begin{figure} \includegraphics{a.jpg} \caption[Long caption]{Caption} \label{pic-a} \end{figure} How can I make images to be always visible on the center of page? ...
22
votes
1answer
830 views

href to an image label - how to jump to the image instead of the caption below the image?

I'm using the following command to embed images in my LaTeX document (which is then rendered as PDF) \newcommand{\img}[4]{ \begin{figure}[!hbt] \centering \vspace{1ex} ...
21
votes
3answers
23k views

making a table fit on a page by moving it left

I have a table where the last columns fall off the page. Instead of making the text smaller I would like the table to not adhere to the margin of where it begins. I would like to move it to the left. ...
21
votes
2answers
12k views

How to place a table on a new page with landscape orientation without clearing the current page?

I'd like to place a table on a new page with landscape orientation. To do so, I use \usepackage{pdflscape} ... \pagestyle{empty} \begin{landscape} \begin{table}[htbp] \begin{center} ...
20
votes
4answers
6k views

How to avoid splitting tables between sections

I have 5 tables and a section after them. After creation of an output file I have two tables on one page, then a section and last 3 tables on next page. What I want to achieve is to put tables and ...
20
votes
2answers
25k views

How to force table caption on top?

I have a table which works ok...as per example below. But in the thesis, the right column is centered and caption forced to below table. Is there a way I can make it look like? ...
20
votes
2answers
3k views

Code spanning over two pages with minted, inside listing with caption

I am trying using minted to display some code in my document, but the code is long and spans over two pages, this works fine, however when I place my code inside \begin{listing} ...
20
votes
2answers
361 views

How can I detect if I'm inside or outside of a float environment?

I am trying to detect whether I am inside or outside a float. I know the way how caption works. It uses the internal \@captype. But in the example below you see that this test failed by using ...
19
votes
2answers
7k views

Beamer Presentation: Figure has no number?

I am giving a presentation and therefore I am using the beamer class. I have included some figures and it works, but there is no number after "Figure". My code: \documentclass{beamer} ...
19
votes
2answers
940 views

How to reference the page of a figure?

Is it possible to make a reference to the page where a figure is rendered? I would like to write something like see figure~\ref{figure-xyz} on page NN where NN will automatically be maintained by ...
19
votes
2answers
3k views

Margin Figures/Captions

I have two figure/caption related questions. Firstly, in many textbooks, it is customary to put thin figures (along with their captions) entirely in the outer margin of the page. What is the most ...