This Expert Advisor finds the direction of the currency pair over the basis of a certain number of bars following which it determines when the correction occurs. If the trend is sufficient and the correction is equivalent to the value specified in the parameters the Expert Advisor will open trades that is in the direction of the trend if additional indicators confirm the trade's opening. This is advantageous because it does not buy at the highest or sell at the lowest of the trend however, it will only do so when the trend has corrected. However, it is feasible to select different values for correction or even 0 if you only wish to trade when trend is in place.
This is an extended version of Trend and correction expert with more flexible parameters and better accuracy in trading opening due to additional indicators.

Input parameters​

  • Lots Lots - Size of the lot (when Lots =0 the size of the lot is calculated on the percentage of money that is free that is in your account);
  • Percentage of money that is free- percent of money free to open every trade (works when the number of lots is zero);
  • MaxSpread - maximum spread to open the deal (for accounts with floating spreads that allow you to open the deal when the spread is not too big);
  • Magicis a unique identifier (you must make it unique if you have several advisors running at the same time in one terminal);
  • StopLoss - Stop Loss (in pips);
  • TakeProfit - Take Profit (in pips);
  • Stop to break even after - set Stop Loss at Breakeven after the specified number of pips
  • AutoClose is enabled Automatically close orders if the reverse signal is detected
    TrailingStopValue Value of the trailing stop in pips, If value is 0 If value is 0, then trailing stop isn't being used; SetStopToLastFractal - enable stop loss through the final fractal (instead of the usual trailing stop);
    • CountBars - number of bars to look for trend and correction;
    • BarsShift - the maximum amount of bars shift when looking for an initial trend;
    • MinPriceDistance - the minimum distance between the trend unit of currency pair to open a deal;
    • PercentCorrection - percentage of correction (recommended from 0 to 62);
    • AdxPeriod - period of the ADX indicator;
    • MinAdxLevel - minimum ADX indicator level
    • Trading start time - trading start time;
    • End of trading hour - trading end hour;
    • PeriodCCI Commodity Channel Index indicator period (0 do not use this indicator);
    LevelsCCI - Commodity Channel Index (CCI) indicator levels;
    • TimeframeADX2 - timeframe of the second ADX indicator (to work with the CCI indicator);
    • PeriodADX2 - period of the second ADX indicator;
    • CCIAndADX2 The dependence of CCI levels on the second ADX indicator;
    • PeriodRSI - the period of the Relative Strength Index indicator (0 Do not use this indicator);
    • TimeframeRSI - time frame of the Relative Strength Index indicator;
    • StepPeriodRSI - Relative Strength Index indicator period change;
    • LevelRSI - Relative Strength Index indicator level;
    • FastOptimizationParameter - Parameter of quick optimization. The higher the number, the faster optimization, however, it will have a lower trading quality. The suggested values are 1 , or zero for trading. Values ranging from 2 to 10 can be set to be used as the initial optimization.
    • ProfitToLossRatio - the allowed ratio of losses to profits (0 is not set, as are other parameters);
    • CntHoursForVerificationOrder - the number of bars to check - if at least one trade was opened;
    • MaxAllowableLoss Maximum allowed loss in the account currency for the specified amount of bars;
    • IncLotAfterProfit - increase the lot after a profitable close of trade
    DecLotAfterLoss Reduce the amount after unprofitable closing of trade;
    • MaxLossCount - maximum number of losing trades, after which you cease trading (0 - not set);
    ShowInfo - show information.
Scalping Fx Bot
First release
Last update
0.00 star(s) 0 ratings

More resources from Scalping Fx Bot