[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"indicator-ma-zh":3},"# 移动平均线基础 (MA)\n\n> 基础移动平均线的 StratCraft 指标页面。\n\n**Route**: `\u002Findicators\u002Fma\u002F`\n\n## 作用\n\nMA 是目录中的基础移动平均线项目。在此数据集中，它也别名为 SMA 和 SimpleMovingAverage（简单移动平均线）。\n\n## 公式\n\n`MA = average(n 周期内的价格)`\n\n## 参数\n\n- `period` - 默认 `30`\n\n## C++23 API\n\n```cpp\n#include \u003Cnonabt\u002Findicators\u002Fma.hpp>\nauto ma = std::make_unique\u003Cnonabt::MA>(data().close(), 30);\n```\n\n## 常见用法\n\n- 将 MA 用作趋势方向的基准。\n- 结合快线和慢线 MA 用于交叉系统。\n- 当你需要一个通用的移动平均线项目时，将其用作更简洁的参考线。\n"]