1
\begin{table}[h+]

This gives a syntax error in pdflatex. I guess I am missing a package, but I cannot think which one it is. I have installed every package I can think of ....

6
  • 5
    Welcome to TeX.SE + seems to be wrong! I don't know this float parameter.
    – user31729
    Commented Jan 2, 2017 at 13:03
  • 4
    I'm curious where you saw + used as a float specifier, I've never seen it before. Any subset of htbp! is valid without packages. Commented Jan 2, 2017 at 13:05
  • 2
    I can only assume that what you were meant (or supposed) to type was \begin{table}[h!]. That, or one or more of the following letters: h, t, b, and p. For sure , if you use ! instead of +, the syntax error is gone.
    – Mico
    Commented Jan 2, 2017 at 13:32
  • 2
    I might also add that using [h] or [h!] will cause the table to go the end of the section/chapter/document or wherever the next \clearpage is if it will not fit on the current page. If you don't want it to float, don't use table at all. Commented Jan 2, 2017 at 14:05
  • 2
    @JohnKormylo - Your comment is correct for [h] but (thankfully for lots of unsuspecting users) not for [h!]: LaTeX automatically changes all instances of [h!] to [ht!]. The effect of [ht!]: if LaTeX can't place the float "right here" on the current page, it will place it at the top of the very next next page.
    – Mico
    Commented Jan 2, 2017 at 14:27

1 Answer 1

3

Up to LaTeX release 2015/01/01, an input such as

\begin{table}[h+]

wouldn't have produced an error, but the + would have done nothing at all.

Starting from that release, illegal characters in the optional argument to a float environment (table, figure or others defined by additional packages) produce an error

Unknown float option `<opt>'

in your case

Unknown float option `+'

Note that the only legal characters are

h t b p !

With the float package, one can use H (alone), but it's not recommended.

2
  • I have been using the + for ages! OH OK maybe it was simply being ignored. Was told by someone it made the placement stronger back in about 2003....
    – Robin
    Commented Jan 3, 2017 at 13:45
  • 1
    @Robin That's !, not +.
    – egreg
    Commented Jan 3, 2017 at 13:45

You must log in to answer this question.

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