Rossbot
This is an expert advisor for the Stairstep Breakouts trading system.
Build the consolidation zone
BoxBuffer: Margin above and below a consolidation zone, beyond which an entry is triggered.
BoxBufferType: Type of BoxBuffer. It can be pips, multiplier of ATR, multiplier of CZ height or multiplier of stop loss value.
BoxLength: Minimum number of bars for a valid consolidation zone.
BoxRange: Maximum height for a valid consolidation zone.
BoxRangeType: Type of BoxRange.
AutoReduceCZ: A consolidation zone is narrowed within its highest and lowest points. False means BoxRange defines its height.
CZPerSession: Maximum number of consolidation zones during each session. If there are no trading sessions, it refers to the whole day. 0 disables this option.
TimeFrame: The timeframe used for calculating the consolidation zones.
Entry and exit conditions
MaxEntryDistance: Entry distance from breakout level should not exceed the defined value. 0 disables this option.
MaxEntryDistanceType: Type of MaxEntryDistance.
AnchorCandle: We set an anchor at the open price of the current candle. The first breakout trade should open above it for longs or below it for shorts.
AnchorCandleTF: The timeframe of anchor candle.
InitialBreakoutDirectionOnly: All trades of a consolidation zone should have the same direction as the first one.
LongTrades: Long trades are allowed.
ShortTrades: Short trades are allowed.
MinBarsClosedOutside: 0 means an entry signal is valid when price exceeds the buffer zone, a value of 1 or greater defines the number of bars that should close beyond the buffer lines for a valid entry.
EMAFilter: An entry is valid when real time moving average also reaches the level of the entry signal.
ReverseSignals: Direction of entry signals is reversed.
CopyIndicator: Trades are opened based only on signals from SSBODynamicBreakoutBox indicator. Take profit and stop loss are also copied from the indicator and are applied to bid. The indicator should be attached on a chart of the same timeframe and share the same MagicNumber.
Build the trading grid
MaxTradeSetReversals: Maximum allowed trades of a trade set.
ResetBoxSize: After a trade set is completed, if the defined number of bars lies within the extended consolidation zone, a new trade set is allowed to occur.
BreakoutBypass: Number of breakout signals omitted before the breakout that triggers a trade.
FIBSasPriceTarget: Take profit is defined by the nearest fibonacci level.
FIB_TP: Fibonacci sequence ratios used to calculate the respective levels.
Trade settings
MagicNumber: Magic number of the trade. If more than one chart of the same pair is opened the magic numbers should be different. Different pairs can have the same magic number.
TradeComment: Comment of the trade as shown at the Metatrader terminal.
TradesPerSession: Maximum number of trades that can be opened during each trading session. It includes open and closed trades. If there are no trading sessions, it refers to the whole day. 0 disables this option.
QuickTakeProfit: Take profit of the first trade of a trade sequence. If ReverseSignals is true and QuickTakeProfit is 0, then the opposite border of the consolidation zone is used as take profit.
QuickTakeProfitType: Type of QuickTakeProfit.
ModifyTakeProfit: After the first trade of a tradeset the take profit value is modified so that it is no less than the greatest stop loss value among all trades of this tradeset.
StopLossOverride: The stop loss value in pips. If ReverseSignals is false and StopLossOverride is 0, then the opposite border of the consolidation zone is used as stop loss.
StopLossOverrideType: Type of StopLossOverride.
BreakEvenTrigger: The stop loss moves to the entry price after price is in profit for the defined value.
BreakEvenTriggerType: Type of break even trigger.
LockProfit: The stop loss moves to the entry price plus the defined value after price reaches BreakEvenTrigger level.
LockProfitType: Type of LockProfit.
TrailingStart: Trailing stop is activated when price goes above the entry price for longs or below the entry price for shorts, for the defined value.
TrailingStartType: Type of TrailingStart.
TrailingStop: Value of trailing stop loss. Stop loss is continuously modified so that its distance from current price is always the defined value. 0 disables this option.
TrailingStopType: Type of trailing stop loss.
TrailingStep: The trailing stop loss is modified when price exceeds the level at which the previous trailing stop modification occurred, for the defined value.
TrailingStepType: Type of TrailingStep.
DynamicTrailingStop: The stop loss is constantly calculated as a percentage of the distance between current price and take profit. 0 disables this option.
CloseProfitableAfterMinutes: At the defined minutes after its opening, a profitable trade is closed.
CloseLosingAfterMinutes: At the defined minutes after its opening, an unprofitable trade is closed.
Slippage: Maximum allowed slippage of trades.
MaxSpread: No trades are opened when spread is greater than the defined pips. 0 disables this option.
VisibleTP: Take profit visible to brokers used in case of disconnection. It is a multiplier of hidden take profit value.
VisibleSL: Stop loss visible to brokers used in case of disconnection. It is a multiplier of hidden stop loss value.
SendEmail: Disabled means no email, TradeOpening means an email is sent only when a trade is opened, TradeClosing means an email is sent only when a trade is closed, TradeOpeningOrClosing means an email is sent in both cases.
SendNotifications: Disabled means no push notification, TradeOpening means a notification is sent only when a trade is opened, TradeClosing means a notification is sent only when a trade is closed, TradeOpeningOrClosing means a notification is sent in both cases.
Alerts: Disabled means no alerts, TradeOpening means alerts only when a trade is opened, TradeClosing means alerts only when a trade is closed, TradeOpeningOrClosing means alerts in both cases.
AlertSound: Play the defined sound file with an alert. The sound file should be placed in the sounds directory of Metatrader. Set it to blank for no sound.
ScreenShots: Screenshots are saved in the files folder at the opening and closing of a trade. Disabled means no screenshots, TradeOpening means a screen shot is saved only when a trade is opened, TradeClosing means a screen shot is saved only when a trade is closed, TradeOpeningOrClosing means a screen shot is saved in both cases.
LongColour: Arrow colour of long trades.
ShortColour: Arrow colour of short trades.
LabelFontColour: Colour of the labels that show information of the expert advisor.
Trading hours settings
All hour based settings are in hhmmhhmm format and refer to GMT. The first four digits define the start time and the last four digits the end time. Up to three trading sessions can be used. Set it to “00002400” to trade all day.
AutoGMTOffset: Difference between server time and GMT, defined automatically by the EA. It can’t be used during backtests.
ManualGMTOffset: Difference between server time and GMT, defined manually.
DSTOffset: If ManualGMTOffset is used, Daylight Saving Time correction is automatically applied according to the European Union rules.
TradingSession1: Trading hours restrictions for the first trading session.
TradingSession2: Trading hours restrictions for the second trading session.
TradingSession3: Trading hours restrictions for the third trading session.
MondayOpenHour: For each week, new trades are only opened after this hour of Monday. It is in hhmm format. Set it to blank to disable this option.
FridayCloseHour: Hour of Friday when all trades are closed and no new ones are opened to avoid the weekend gap. It is in hhmm format. Set it to blank to disable this option.
FridayCloseTrades: At FridayCloseHour open trades are closed. None means no trades are closed, ProfitableTrades means only profitable trades are closed, LosingTrades means only losing trades are closed, AllTrades means all trades are closed.
DailyCloseHour: Hour of each day when all trades are closed and no new ones are opened till the next day. It is in hhmm format. Set it to blank to disable this option.
DailyCloseTrades: At DailyCloseHour open trades are closed. None means no trades are closed, ProfitableTrades means only profitable trades are closed, LosingTrades means only losing trades are closed, AllTrades means all trades are closed.
TradingDays: Comma separated days of the week that allow trading.
NewsFilter: No new trades are opened during news period.
MinutesBeforeNews: The NewsFilter is active for the defined number of minutes before news.
MinutesAfterNews: The NewsFilter is active for the defined number of minutes after news.
Money management settings
Lots: The lot size if money management is not used.
MoneyManagement: True means that the lot size is defined by the money management.
EquityPercent: Lot size is a percent of account equity. 0 disables this option.
StopLossRisk: Percent of account balance to risk for each trade, if it hits stop loss. 0 disables this option. Only one of EquityPercent or StopLossRisk can be used.
CZResetMartingale: Martingale sequence resets when a new CZ is formed.
Martingale: Percentage means a LotMultiplier percentage is added to the lot size after a loss, Multiplication means the lot size is multiplied by LotMultiplier after a loss. Martingale is activated only after the initial lots of a trade are closed at loss because of stop loss.
LotMultiplier: Lot size increase factor in case of Martingale.
StartMartingaleAfterSL: The lot size change starts after the defined number of consecutive unprofitable closed trades.
MaxMartingaleSequence: The maximum number of consecutive martingaled trades.
You can press the Wipe Clean button to erase all past CZs so the EA trades as it has just been attached to chart. Before installing this expert advisor, access the menu Tools → Options → Expert Advisors and make sure that “Allow DLL imports” is enabled.
Build the consolidation zone
BoxBuffer: Margin above and below a consolidation zone, beyond which an entry is triggered.
BoxBufferType: Type of BoxBuffer. It can be pips, multiplier of ATR, multiplier of CZ height or multiplier of stop loss value.
BoxLength: Minimum number of bars for a valid consolidation zone.
BoxRange: Maximum height for a valid consolidation zone.
BoxRangeType: Type of BoxRange.
AutoReduceCZ: A consolidation zone is narrowed within its highest and lowest points. False means BoxRange defines its height.
CZPerSession: Maximum number of consolidation zones during each session. If there are no trading sessions, it refers to the whole day. 0 disables this option.
TimeFrame: The timeframe used for calculating the consolidation zones.
Entry and exit conditions
MaxEntryDistance: Entry distance from breakout level should not exceed the defined value. 0 disables this option.
MaxEntryDistanceType: Type of MaxEntryDistance.
AnchorCandle: We set an anchor at the open price of the current candle. The first breakout trade should open above it for longs or below it for shorts.
AnchorCandleTF: The timeframe of anchor candle.
InitialBreakoutDirectionOnly: All trades of a consolidation zone should have the same direction as the first one.
LongTrades: Long trades are allowed.
ShortTrades: Short trades are allowed.
MinBarsClosedOutside: 0 means an entry signal is valid when price exceeds the buffer zone, a value of 1 or greater defines the number of bars that should close beyond the buffer lines for a valid entry.
EMAFilter: An entry is valid when real time moving average also reaches the level of the entry signal.
ReverseSignals: Direction of entry signals is reversed.
CopyIndicator: Trades are opened based only on signals from SSBODynamicBreakoutBox indicator. Take profit and stop loss are also copied from the indicator and are applied to bid. The indicator should be attached on a chart of the same timeframe and share the same MagicNumber.
Build the trading grid
MaxTradeSetReversals: Maximum allowed trades of a trade set.
ResetBoxSize: After a trade set is completed, if the defined number of bars lies within the extended consolidation zone, a new trade set is allowed to occur.
BreakoutBypass: Number of breakout signals omitted before the breakout that triggers a trade.
FIBSasPriceTarget: Take profit is defined by the nearest fibonacci level.
FIB_TP: Fibonacci sequence ratios used to calculate the respective levels.
Trade settings
MagicNumber: Magic number of the trade. If more than one chart of the same pair is opened the magic numbers should be different. Different pairs can have the same magic number.
TradeComment: Comment of the trade as shown at the Metatrader terminal.
TradesPerSession: Maximum number of trades that can be opened during each trading session. It includes open and closed trades. If there are no trading sessions, it refers to the whole day. 0 disables this option.
QuickTakeProfit: Take profit of the first trade of a trade sequence. If ReverseSignals is true and QuickTakeProfit is 0, then the opposite border of the consolidation zone is used as take profit.
QuickTakeProfitType: Type of QuickTakeProfit.
ModifyTakeProfit: After the first trade of a tradeset the take profit value is modified so that it is no less than the greatest stop loss value among all trades of this tradeset.
StopLossOverride: The stop loss value in pips. If ReverseSignals is false and StopLossOverride is 0, then the opposite border of the consolidation zone is used as stop loss.
StopLossOverrideType: Type of StopLossOverride.
BreakEvenTrigger: The stop loss moves to the entry price after price is in profit for the defined value.
BreakEvenTriggerType: Type of break even trigger.
LockProfit: The stop loss moves to the entry price plus the defined value after price reaches BreakEvenTrigger level.
LockProfitType: Type of LockProfit.
TrailingStart: Trailing stop is activated when price goes above the entry price for longs or below the entry price for shorts, for the defined value.
TrailingStartType: Type of TrailingStart.
TrailingStop: Value of trailing stop loss. Stop loss is continuously modified so that its distance from current price is always the defined value. 0 disables this option.
TrailingStopType: Type of trailing stop loss.
TrailingStep: The trailing stop loss is modified when price exceeds the level at which the previous trailing stop modification occurred, for the defined value.
TrailingStepType: Type of TrailingStep.
DynamicTrailingStop: The stop loss is constantly calculated as a percentage of the distance between current price and take profit. 0 disables this option.
CloseProfitableAfterMinutes: At the defined minutes after its opening, a profitable trade is closed.
CloseLosingAfterMinutes: At the defined minutes after its opening, an unprofitable trade is closed.
Slippage: Maximum allowed slippage of trades.
MaxSpread: No trades are opened when spread is greater than the defined pips. 0 disables this option.
VisibleTP: Take profit visible to brokers used in case of disconnection. It is a multiplier of hidden take profit value.
VisibleSL: Stop loss visible to brokers used in case of disconnection. It is a multiplier of hidden stop loss value.
SendEmail: Disabled means no email, TradeOpening means an email is sent only when a trade is opened, TradeClosing means an email is sent only when a trade is closed, TradeOpeningOrClosing means an email is sent in both cases.
SendNotifications: Disabled means no push notification, TradeOpening means a notification is sent only when a trade is opened, TradeClosing means a notification is sent only when a trade is closed, TradeOpeningOrClosing means a notification is sent in both cases.
Alerts: Disabled means no alerts, TradeOpening means alerts only when a trade is opened, TradeClosing means alerts only when a trade is closed, TradeOpeningOrClosing means alerts in both cases.
AlertSound: Play the defined sound file with an alert. The sound file should be placed in the sounds directory of Metatrader. Set it to blank for no sound.
ScreenShots: Screenshots are saved in the files folder at the opening and closing of a trade. Disabled means no screenshots, TradeOpening means a screen shot is saved only when a trade is opened, TradeClosing means a screen shot is saved only when a trade is closed, TradeOpeningOrClosing means a screen shot is saved in both cases.
LongColour: Arrow colour of long trades.
ShortColour: Arrow colour of short trades.
LabelFontColour: Colour of the labels that show information of the expert advisor.
Trading hours settings
All hour based settings are in hhmmhhmm format and refer to GMT. The first four digits define the start time and the last four digits the end time. Up to three trading sessions can be used. Set it to “00002400” to trade all day.
AutoGMTOffset: Difference between server time and GMT, defined automatically by the EA. It can’t be used during backtests.
ManualGMTOffset: Difference between server time and GMT, defined manually.
DSTOffset: If ManualGMTOffset is used, Daylight Saving Time correction is automatically applied according to the European Union rules.
TradingSession1: Trading hours restrictions for the first trading session.
TradingSession2: Trading hours restrictions for the second trading session.
TradingSession3: Trading hours restrictions for the third trading session.
MondayOpenHour: For each week, new trades are only opened after this hour of Monday. It is in hhmm format. Set it to blank to disable this option.
FridayCloseHour: Hour of Friday when all trades are closed and no new ones are opened to avoid the weekend gap. It is in hhmm format. Set it to blank to disable this option.
FridayCloseTrades: At FridayCloseHour open trades are closed. None means no trades are closed, ProfitableTrades means only profitable trades are closed, LosingTrades means only losing trades are closed, AllTrades means all trades are closed.
DailyCloseHour: Hour of each day when all trades are closed and no new ones are opened till the next day. It is in hhmm format. Set it to blank to disable this option.
DailyCloseTrades: At DailyCloseHour open trades are closed. None means no trades are closed, ProfitableTrades means only profitable trades are closed, LosingTrades means only losing trades are closed, AllTrades means all trades are closed.
TradingDays: Comma separated days of the week that allow trading.
NewsFilter: No new trades are opened during news period.
MinutesBeforeNews: The NewsFilter is active for the defined number of minutes before news.
MinutesAfterNews: The NewsFilter is active for the defined number of minutes after news.
Money management settings
Lots: The lot size if money management is not used.
MoneyManagement: True means that the lot size is defined by the money management.
EquityPercent: Lot size is a percent of account equity. 0 disables this option.
StopLossRisk: Percent of account balance to risk for each trade, if it hits stop loss. 0 disables this option. Only one of EquityPercent or StopLossRisk can be used.
CZResetMartingale: Martingale sequence resets when a new CZ is formed.
Martingale: Percentage means a LotMultiplier percentage is added to the lot size after a loss, Multiplication means the lot size is multiplied by LotMultiplier after a loss. Martingale is activated only after the initial lots of a trade are closed at loss because of stop loss.
LotMultiplier: Lot size increase factor in case of Martingale.
StartMartingaleAfterSL: The lot size change starts after the defined number of consecutive unprofitable closed trades.
MaxMartingaleSequence: The maximum number of consecutive martingaled trades.
You can press the Wipe Clean button to erase all past CZs so the EA trades as it has just been attached to chart. Before installing this expert advisor, access the menu Tools → Options → Expert Advisors and make sure that “Allow DLL imports” is enabled.