거래 로봇을 무료로 다운로드 하는 법을 시청해보세요
당사를 Facebook에서 찾아주십시오!
당사 팬 페이지에 가입하십시오
스크립트가 흥미로우신가요?
그렇다면 링크 to it -
하셔서 다른 이들이 평가할 수 있도록 해보세요
스크립트가 마음에 드시나요? MetaTrader 5 터미널에서 시도해보십시오
지표

Detection of the divergences - MetaTrader 4용 지표

조회수:
42784
평가:
(46)
게시됨:
2015.12.10 14:04
업데이트됨:
2016.11.22 07:32
MQL5 프리랜스 이 코드를 기반으로 한 로봇이나 지표가 필요하신가요? 프리랜스로 주문하세요 프리랜스로 이동

The indicator displays divergences in the form of two matched lines: one on the price chart, the other — on the indicator chart. It allows to register four classes of divergences. For each of the divergence class there is a switch to indicate the necessity of its registration, as well as the color selection of the bull and the bear divergence lines:


One of the six standard indicators included in the DivergenceViewer (RSI, MACD, Momentum, RVI, Stochastic, Standard Deviation) is used as an indicator that serves as data source for the lookup of the divergences with the price (in the indicator's terminology — the base indicator). The indicator can also operate with two non-standard indicators: Derivative and William Blau.

The parameters of the base indicator are set in the input parameter block with the same name:


The parameters should be set in the same order as they are presented in the standard indicator. For example, for the Stochastic base indicator the accordance will be as follows:

  • "The first calculation period" — %K,
  • "The second calculation period" — %D,
  • "The third calculation period" — slowing.

If the number of the base indicator parameters is less than three, then the corresponding calculation periods are simply not displayed, and the values of these parameters are ignored. So, for the RSI and the Momentum indicators it is sufficient to set the values of only two parameters: "The first calculation period" and "Indicator calculation price".

If some other indicator needs to used as the base indicator, then choose the value "Custom" in the "Base indicator" parameter, and fill the following lines in the "Custom indicator" block:

  1. "Indicator name" — the name of an indicator, which is present in the "Navigator" window of the terminal. Specified without the extension.
  2. "Index of the buffer for data pickup" — the index of the indicator line, values of which will be used for plotting the base indicator chart (most often — 0).
  3. "Number of the indicator parameters" — specify the amount of the input parameters used by the indicator. If set to 0, then the default parameter values will be used for the base indicator.
  4. "Value of the N-th parameter" — set the values of the corresponding parameters of the base indicator.

After setting up the base indicator it is necessary to determine the maximum length of the divergence by filling the "Depth of the 2-nd support point lookup" parameter, and to define how much the price extremums must match the indicator extremums — the "From price extremum to indicator extremum" parameter.

The divergence registration is based on the local extremum lookup. To form any extremum at least three bars are needed, the central of which is the extremum. For that reason, the registration of the divergences is made with a two bar delay. The figure shows the class A divergences and bars marked with vertical lines (not part of the indicator), which show the divergence registration places.

The full description of the indicator capabilities and its formation logic is available in the "Divergences on the current chart" article.

MetaQuotes Ltd에서 러시아어로 번역함.
원본 코드: https://www.mql5.com/ru/code/13784

OrderTimeAlert OrderTimeAlert

The Expert Advisor watches the market orders and generates a sound signal after a predefined time from the moment of order opening.

Elementary trailing stop Elementary trailing stop

Elementary trailing stop able to distinguish its "own" orders among others by comment and/or Magic number. It also distinguishes the financial instrument that needs to be trailed.

Derivative Derivative

The indicator performs the calculation of the derivative of the price.

Road Map Road Map

The indicator displays the series of waves, breakthrough points and targets for Take Profit.