Watch how to download trading robots for free
Find us on Facebook!
Join our fan page
Interesting script?
So post a link to it -
let others appraise it
You liked the script? Try it in the MetaTrader 5 terminal
Experts

Flat Channel - expert for MetaTrader 5

Published by:
Vladimir Karputov
Views:
5224
Rating:
(21)
Published:
2019.01.02 14:30
Flat Channel.mq5 (88.53 KB) view
\MQL5\Indicators\
Need a robot or indicator based on this code? Order it on Freelance Go to Freelance

Idea by JS_Sergey

mq5 code author - barabashkakvn

The Expert Advisor uses the  Standard Deviation smoothing custom indicator, which is a smoothed Standard Deviation. Determine trend existence based on the indicator values on bars #0, #1, #2, #3 and #4: 

(StdDev #0 > StdDev #1)  && (StdDev #1 > StdDev #2)  && (StdDev #2 > StdDev #3)  && (StdDev #3 > StdDev #4) -> there is a trend

It also determines flat within the "Minimum number of bars" bars. A flat zone is indicated by two lines:

Flat Channel

If there is no flat zone currently in the market, the EA does not place pending orders. Also, if there is no flat, appropriate lines are deleted from the chart. When any of the pending orders triggers, other pending orders are deleted, and trailing stop is further applied to positions.

Stop Loss and Take Profit can be set both as constant or dynamic values. This depends on the Stop loss andTake Profit parameters. The lot value can also be either constant ("Enable the money management function" is set to "false") or dynamic. This depends on the number of trades closed by Stop Loss and Take Profit.

EURUSD,M30:

Flat Channel

Translated from Russian by MetaQuotes Ltd.
Original code: https://www.mql5.com/ru/code/23139

Normalized_Volume Normalized_Volume

The Normalized Volume indicator

MA_Trend MA_Trend

MA Trend indicator

Exp_Slow-Stoch_Duplex Exp_Slow-Stoch_Duplex

Two identical trading systems (for long and short positions) based on the signals of the Slow-Stoch indicator, which can be configured in different ways within one Expert Advisor

MACD_MFI MACD_MFI

The MFI indicator (Money Flow Index) applied over MACD (Moving Average Convergence/Divergence) provides a visual presentation of the current price divergence