> 函數名:DX
名稱:動向指標或趨向指標
簡介:通過分析股票價格在漲跌過程中買賣雙方力量均衡點的變化情況,即多空雙方的力量的變化受價格波動的影響而發生由均衡到失衡的循環過程,從而提供對趨勢判斷依據的一種技術指標。
分析和應用:
[百度百科](https://baike.baidu.com/item/DMI%E6%8C%87%E6%A0%87/3423254?fr=aladdin)
[維基百科](https://zh.wikipedia.org/wiki/%E5%8B%95%E5%90%91%E6%8C%87%E6%95%B8)
[同花順學院](http://www.iwencai.com/school/search?cg=100&w=DMI)
NOTE: The ``DX`` function has an unstable period.
```python
real = DX(high, low, close, timeperiod=14)
```
Learn more about the Directional Movement Index at [tadoc.org](http://www.tadoc.org/indicator/DX.htm).
### MACD - Moving Average Convergence/Divergence
> 函數名:MACD
名稱:平滑異同移動平均線
簡介:利用收盤價的短期(常用為12日)指數移動平均線與長期(常用為26日)指數移動平均線之間的聚合與分離狀況,對買進、賣出時機作出研判的技術指標。
分析和應用:[百度百科](https://baike.baidu.com/item/MACD%E6%8C%87%E6%A0%87?fromtitle=MACD&fromid=3334786)
[維基百科](https://zh.wikipedia.org/wiki/MACD)
[同花順學院](http://www.iwencai.com/school/search?cg=100&w=MACD)
```python
macd, macdsignal, macdhist = MACD(close, fastperiod=12, slowperiod=26, signalperiod=9)
```
Learn more about the Moving Average Convergence/Divergence at [tadoc.org](http://www.tadoc.org/indicator/MACD.htm).
### MACDEXT - MACD with controllable MA type