# Symbol Mapping

{% hint style="info" %}
本設定教學是搭配 MultiCharts 内建的功能使用，可以在 MultiCharts 内的交易追蹤器查詢到商品在期貨商的部位，缺點是每個月都要進行換月的操作。

如果你不需要在 MultiCharts 看到期貨商的部位，可以參考：[免換月設定](/touchance/multicharts/jiao-yi-chuan-jie/symbol-mapping/mian-huan-yue-she-ding.md) 説明。
{% endhint %}

{% hint style="warning" %}
Symbol Mapping 對手動交易和自動交易都有影響。
{% endhint %}

{% hint style="danger" %}
使用本設定方式，在商品結算後，在下個交易日前請先做好 Symbol Mapping，避免下單失敗。

説明：換月後如果沒有正確的進行 Symbol Mapping ，下單洗價商品的合約月份會使用已經結算的合約月份造成下單錯誤，請務必確認商品合約月份正確。
{% endhint %}

{% hint style="danger" %}
依照本次設定換月操作 Symbol Mapping 時，請務必要停止自動交易，完成 Symbol Mapping 後再啓動自動交易，MultiCharts 才會套用新的設定。
{% endhint %}

## **換月 Symbol Mapping 設定步驟**

1. 我們以台指期貨為範例
2. 台指期貨在每月的第 3 個星期三結算，因此在下午盤開盤前( 14:55 - 15:00）必須完成 Symbol Mapping 作業。
3. 標準流程
   1. 停止策略自動交易（每個策略的 SA/AA 為關閉狀態）
   2. 點擊 SA/AA 的下拉按鈕後，出現選單。<br>

      <figure><img src="/files/nYN7EG61JL4IA8mDuI0W" alt=""><figcaption></figcaption></figure>
   3. 點擊 Symbol Mapping<br>

      <figure><img src="/files/MZqACUKw99qlpw0vij4I" alt=""><figcaption></figcaption></figure>
   4. 找到要換月的商品，點擊 Auto<br>

      <figure><img src="/files/nVYRoLKQ1mEKzHVVwDYf" alt=""><figcaption></figcaption></figure>
   5. 確認合約正確變換，例如 2511 -> 2512<br>

      <figure><img src="/files/KU6laoqkIEgG03vUALri" alt=""><figcaption></figcaption></figure>
   6. 點擊 Apply 完成設定
4. 點擊 Auto 無法切換時
   1. 點擊 Auto 無法切換可能是因爲 Server 商品代碼的對應還沒有轉換，建議可以手動輸入。
   2. 點擊 Edit<br>

      <figure><img src="/files/fWa1F83GvUQNtNB0zEQK" alt=""><figcaption></figcaption></figure>
   3. 手動輸入正確合約月份，確認到期日正確，按下 Apply 即可完成設定。<br>

      <figure><img src="/files/qfBLn4j4ZNMGFyp4NE88" alt=""><figcaption></figcaption></figure>
5. 完成設定，重新啓動策略<br>

   <figure><img src="/files/B9njWxkwdmu1xrE47iny" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: 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:

```
GET https://touchance-1.gitbook.io/touchance/multicharts/jiao-yi-chuan-jie/symbol-mapping.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
