> For the complete documentation index, see [llms.txt](https://overleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://overleaf-pro.ayaka.space/latex/zh-tw/latex-cuo-wu/28-no-positions-in-optional-float-specifier.md).

# 可選浮動體指定符號中沒有位置

這是一個標準的 LaTeX 錯誤，當你未包含一個 [浮動體位置指定符](/latex/zh-tw/tu-biao-yu-biao-ge/02-positioning-images-and-tables.md) 在浮動體的選項中，也就是 **`ht`** 中插入一個 **`\begin{figure}[ht]`**。浮動體定位參數是一個選項，可讓我們更有效地控制圖形的放置位置。可用的不同放置選項如下：

| 指定符    | 允許                                                                          |
| ------ | --------------------------------------------------------------------------- |
| h      | 放置浮動體 *這裡*，也就是， *大約* 在其出現在原始文字中的同一位置（不過，並非 *精確地* 就在該位置）                     |
| 的區域變數中 | 位置於 *頂端* 頁面頂端。                                                              |
| b      | 位置於 *底端* 頁面頂端。                                                              |
| p      | 放到一個專用的 *page* 僅供浮動體使用的頁面上。                                                 |
| !      | 覆寫 LaTeX 用來判定「良好」浮動體位置的內部參數。                                                |
| H      | 將浮動體精確放在 LaTeX 程式碼中的位置。需要 *float* 套件（*\usepackage{float}*）。這在某種程度上等同於 *h!*. |

這些 *浮動體定位符* 在建立浮動體時可以放在方括號內，例如 **`\begin{figure}[h]`**。甚至可以組合使用，例如 **`\begin{figure}[!htb]`**，這會告訴 LaTeX 將圖形放置在 *這裡*、或 *頂端*、或 *底端*。如果你像這樣把方括號留空 **`\begin{table}[]`**，就會出現如下所示的錯誤訊息。

main.tex

可選浮動體定位符中沒有位置。

## 如何解決此錯誤

**移除方括號：**

擺脫此錯誤的最簡單方法，是在不使用浮動體定位符時移除方括號，也就是說，不要寫 **`\begin{figure}[]`**，你只需寫 **`\begin{figure}`**.

**插入浮動體定位符：**

解決此錯誤的另一種方法，是插入一個 [浮動體位置指定符](/latex/zh-tw/tu-biao-yu-biao-ge/02-positioning-images-and-tables.md) ，以告訴 LaTeX 你希望浮動體出現的位置。這應該放在方括號中，例如 **`\begin{figure}[h]`** 或 **`\begin{table}[!htb]`**.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://overleaf-pro.ayaka.space/latex/zh-tw/latex-cuo-wu/28-no-positions-in-optional-float-specifier.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
