- 显示:
- 919
- 等级:
- 已发布:
- 2018.06.11 17:10
-
需要基于此代码的EA交易或指标吗?请在自由职业者服务中订购 进入自由职业者服务
J.Ehlers 的瞬时趋势线按以下公式计算:
如果 i<=7:
ITrend[i] = (Price[i] + 2*Price[i-1] + Price[i-2])/4
如果 i>7:
ITrend[i] = c1*Price[i] + c2*Price[i-1] - c3*Price[i-2] + c4*ITrend[i-1] - c5*ITrend[i-2]
其中
c1 = Alpha - 0.25*Alpha*Alpha, c2 = 0.5*Alpha*Alpha, c3 = Alpha - 0.75*Alpha*Alpha, c4 = 2*(1 - Alpha), c5 = (1 - Alpha)*(1 - Alpha), Alpha = 2/(Period + 1)
指标有两个输入参数:
- Period - 计算周期;
- Applied price - 用于计算的价格类型。
由MetaQuotes Ltd译自俄语
原代码: https://www.mql5.com/ru/code/20421