- 显示:
- 1429
- 等级:
- 已发布:
- 2013.12.24 12:24
- 已更新:
- 2023.03.29 14:31
-
需要基于此代码的EA交易或指标吗?请在自由职业者服务中订购 进入自由职业者服务
SpreadInfo 显示当前点差, 它的平均值和速率显示在图表边角。字体类型, 颜色和大小可以在输入参数中自定义。
指标编译时用到 SmoothAlgorithms.mqh 库中的 СMoving_Average 类。类库的使用描述可参阅文章 "Averaging Price Series for Intermediate Calculations Without Using Additional Buffers(无需使用额外的缓冲区进行平均价格序列的中间计算)",另外 type_font 和 CFontName 类来自 GetFontName.mqh 库。
指标输入参数:
//+----------------------------------------------+ //| Indicator input parameters | //+----------------------------------------------+ input string SpName="Spread"; // 点差名 input string MaSpName="MASpread"; // 平均点差名 input string RatioName="Ratio"; // 点差和它的平均值速率名 input color TextColor1=Magenta; // 点差颜色 input color TextColor2=Blue; // 平均点差颜色 input color TextColor3=Red; // 点差和它的平均值速率颜色 input int FontSize=15; // 字号 input type_font FontType=Font14; // 字体 input ENUM_BASE_CORNER WhatCorner=CORNER_RIGHT_UPPER; // 边角位置 input uint Y_=1; // 垂直位置 input uint X_=5; // 水平位置 input int period=100; // 点差平滑周期
由MetaQuotes Ltd译自俄语
原代码: https://www.mql5.com/ru/code/647

本指标的依据,是 Joe DiNapoli 的书 "Trading with DiNapoli Levels (以 DiNapoli 级别交易)" 给出的描述。它被设计用来评估实际市场的超买超卖状态。

XMACD_HTF_Signal 显示 XMACD 指标 的后三根柱线的趋势方向对应的三个图形对象。