Conventions: 0 usually disables a threshold; time uses
HH:MM:SS; money is in account currency; lot sizes are always normalized to broker rules.Risk: DCA, multipliers, and Lot Balance can rapidly increase exposure, margin usage, and drawdown. Test with Strategy Tester and a demo account.
Key Level colors: Bullish FVG is blue; Bearish FVG orange; Liquidity High/Low gold; support green; resistance pink; BUY zones green; SELL zones red. Rectangles are translucent, so overlapping green BUY and red/orange SELL zones may appear purple. This marks overlap/conflict, not a separate signal type.
Online license: In MT5, open Tools → Options → Expert Advisors, enable Allow WebRequest, and add
https://mtsea-lima.metatechsolutions.vn. Enable Notifications for expiry alerts.EA Identity
Order identification and trading direction modes.
Processing logic: TradeMode defines the initial direction state. BUY_AND_SELL allows two chains; BUY_OR_SELL permits only one direction at a time. ONLY_BUY/ONLY_SELL match the corresponding control buttons. UI buttons and shortcuts can still change the direction during a running session.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| MagicNumber | 0 | EA magic number. | Use a unique value for each EA; 0 also takes over manual trades. |
| OrderComment | MATSEA | Order comment prefix. | CHoCH uses OrderComment|B|0|CH|timeframe or OrderComment|S|0|CH|timeframe, e.g. MATSEA|B|0|CH|1 on M1; no timestamp is added. Standard Entry uses OrderComment|B|0|source or OrderComment|S|0|source: ST=Stochastic, RS=RSI, TR=Supertrend, CD=Candle with Entry lots, SR=Stochastic Reverse, BB=Bollinger Bands. Enabled sources confirming the order direction are joined by +, e.g. MATSEA|B|0|ST+RS or MATSEA|S|0|BB. Only matching directions from the current cache are included, not neutral or disabled sources. Separate Candle mode retains |CS; CHoCH retains |CH|timeframe; DCA classification is unchanged. AwareTrend follows the same source format: SA with Auto SL/TP off, SA3 with it on, e.g. MATSEA|B|0|SA, MATSEA|S|0|SA3, or RS+SA3 for agreement. Combined Candle/CHoCH with Auto SAT retains its tag and adds SA3. No prefix is added before OrderComment. Older orders starting with SA3| still receive partial-TP management. |
| TradeMode | BUY_AND_SELL | Allow both chains or restrict trading direction. | MATS_BUY_AND_SELL, MATS_BUY_OR_SELL, MATS_ONLY_BUY, or MATS_ONLY_SELL. On reinitialization, the TradeMode input takes priority over saved button state. |
General
Lot size and protection for the first order in a chain.
Processing logic: A Candle order starting a new chain also uses FirstTPPips/FirstSLPips; CandleSignalLot only changes volume. See the Auto SAT overrides below.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| InitialLots | 0.04 | Base lot size for the first order; Candle fallback when CandleSignalLot=0. | May be affected by the time-based lot profile. |
| FirstTPPips | 200 | Broker TP for the first order; 0 disables it. | Also applies when Candle starts a chain. Entry with SelfAwareTrend and UseSelfAwareAutoSLTP=true uses TP1/TP2/TP3 based on R. |
| FirstSLPips | 0 | Broker SL for the first order; 0 disables it. | Also applies when Candle starts a chain. Entry with SelfAwareTrend and UseSelfAwareAutoSLTP=true gives priority to automatic SL. |
| OpenOnNewCandle | true | Limit Entry/Candle/Bias entries to one per EntryTimeframe candle. | Entry can occur immediately if no order has opened in the current candle; otherwise wait for the next candle. DCA timing remains controlled by DcaType. |
Timeframes
Timeframes for signals, trends, Zone AI, and the Bias Filter.
Processing logic: EntryTimeframe drives new-bar/candle processing. TrendTimeframe is used by EMA, MACD, ADX + DI, and Market Structure. HigherTimeframe provides HTF Alignment, Zone AI, and Bias/Key Levels. Filters read closed candles to avoid incomplete signals. With UseAutoCandleStopLoss=true, Candle signals still use EntryTimeframe, while structural invalidation, swings, and ATR(14) come from closed TrendTimeframe candles.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| EntryTimeframe | M1 | Shared timeframe for Entry sources, including Stochastic Reverse and Bollinger Bands. | Reverse/BB have no separate timeframe: this input changes both their indicator timeframe and candle clock. DCA also uses it for limits/timing according to DcaType. SelfAwareTrend uses it as well. |
| TrendTimeframe | M15 | Trend timeframe. | EMA, MACD, ADX + DI, and Market Structure use this timeframe. Auto Candle SL also uses it to find invalidation highs/lows and the nearest confirmed swing. |
| HigherTimeframe | H1 | HTF context for HTF Alignment, Zone AI, and the Bias Filter. | HTF Alignment and Bias read closed HTF candles; changing this timeframe changes direction, structure, and points of interest. |
Trend Strategy Suggestion
Select an EMA, MACD, ADX + DI, Market Structure, and HTF Alignment preset, or NONE for manual inputs. Presets do not change timeframes or automatically enable/disable filters.
Processing logic: MT5 does not let one input rewrite the displayed value of another. A selected preset supplies the complete internal profile even though the input fields still show the manual values. Select NONE to use and adjust those values directly. The Trend UI always displays the effective values.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| TrendStrategySuggestion | MATS_TREND_NONE | Trend strategy profile or manual-input mode. | NONE: use inputs directly, with no fallback. FAST: EMA 9/21, MACD 8/21/5, ADX 10 with minimum 18, Structure 40/2, HTF 20/50. BALANCED: 21/55, 12/26/9, 14 with minimum 22, 80/3, 50/200. SAFE: 34/89, 24/52/9, 14 with minimum 25, 120/4, 50/200. LONG_TERM: 50/200, 30/65/12, 20 with minimum 25, 200/5, 100/200. |
Limits
Limits on open positions per side, spread, lot size, and entry frequency.
Processing logic: MaxLots caps every order, including Candle. CandleSignalLot=0.50 requires MaxLots≥0.50 for the full volume. MaxBuyOrders/MaxSellOrders are checked at the shared order gateway against open positions matching the symbol and EA magic, including the Balance magic offset. MagicNumber=0 includes all positions on the symbol. For example, with MaxBuyOrders=20, 5 Entry + 4 Candle + 3 Bias + 6 DCA + 2 Balance BUY positions block further BUY entries; SELL has its own limit. Closing positions frees capacity. Special tags do not advance DCA progression but still count toward these limits.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| MaxBuyOrders | 20 | Maximum open BUY positions within the EA scope. | Counts Entry, Candle, Bias, DCA, and Balance, including INDEPENDENT Balance; does not use dcaCount to check the limit. |
| MaxSellOrders | 20 | Maximum open SELL positions within the EA scope. | Counts Entry, Candle, Bias, DCA, and Balance, including INDEPENDENT Balance; does not use dcaCount to check the limit. |
| MaxSpreadPips | 30 | Block new orders when spread is too high. | Adjust for the symbol. |
| MaxLots | 0.25 | Maximum lot size per order. | Broker maximum volume and lot step also apply. |
| OpenDelaySeconds | 2 | Normal delay between order openings. | Exception: one |CS or |BF order may accompany one DCA in the same tick; that DCA bypasses the open delay. |
Lots by time window
Override the lot profile during a local-time window.
Processing logic: Within the local-time window, separate profiles apply to standard Entry, Candle, Bias, the shared Entry/DCA lot cap, and pruning. DCA uses InitialLots (or ResetLots after auto reset) and LotMode as its base, not LotTimeNewLots/LotTimeCandleLots/LotTimeBiasLots. Entry and DCA use LotTimeMaxLots inside the window and MaxLots outside; DCA auto reset follows the active cap. ADD mode still adds LotAddFactor to the latest open DCA/standard Entry lot; Candle/Bias do not change the DCA anchor. Example: InitialLots=0.1, multiplier=1.5, dcaCount=1 gives a MULTIPLY DCA lot of 0.15 even if LotTimeNewLots=0.01, provided the cap allows it. With LotTimeMaxLots=0.1 and auto reset off, volume is capped at 0.1.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseLotByTime | false | Enable the time-based profile. | Adjust exposure by session. |
| LotTimeStart | 11:00:00 | Local-time window start. | The window may cross midnight. |
| LotTimeEnd | 21:00:00 | Local-time window end. | The window may cross midnight. |
| LotTimeNewLots | 0.01 | Standard Entry lot size inside the window. | Does not change the base DCA lot; UseCurrentDcaLotForEntry still applies if enabled. |
| LotTimeCandleLots | 0.1 | Separate Candle Entry lot size inside the window. | 0 uses LotTimeNewLots; the final lot is still capped by LotTimeMaxLots and broker limits. |
| LotTimeBiasLots | 0.1 | Separate Bias Entry lot size inside the window. | 0 uses LotTimeNewLots; outside the window, revert to BiasFilterLot. |
| LotTimeMaxLots | 0.25 | Lot cap for both Entry and DCA inside the window. | LotTimeMaxLots applies inside, MaxLots outside. The auto-reset threshold follows the active cap. |
| LotTimeMinPruneLot | 0.10 | Minimum lot size for partial pruning. | Temporary override during the window. |
Auto lot reset (at max lot)
Switch profiles when DCA lot size reaches the cap.
Processing logic: The EA latches ResetLots/ResetMultiplier/ResetChainTPPips and restores the state after restart.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseAutoLotReset | false | Enable progression reset. | Does not close the chain. |
| ResetLots | 0.01 | Lot size after reset. | Must be greater than 0. |
| ResetMultiplier | 1.2 | Multiplier after reset. | Usually lower than the initial value. |
| ResetChainTPPips | 200 | Chain TP after reset. | Used for chain exit. |
Entry conditions
Independently select Stochastic, RSI, Supertrend, Candle, CHoCH, Stochastic Reverse, Bollinger Bands, and the additional adaptive SelfAwareTrend reversal source. They share EntryTimeframe; there is no SATS dashboard.
Processing logic: Each source returns BUY (+1), SELL (-1), or NONE (0) from closed candles. AND requires every participating signal to be nonzero and in the same direction. OR needs at least one nonzero signal, but simultaneous BUY and SELL cancel the result. Combined signals must still pass all safety gates.
Candle participates when EntryCandle or UseCandleSignalForEntry is true. EntryCandle=true with UseCandleSignalForEntry=false uses Entry lots to start a chain and does not add separate Candle orders. If UseCandleSignalForEntry=true, Candle logic and lots take priority, including time-based lot rules, regardless of EntryCandle. Both false disables Candle trading. Candle participates only once and shares a persisted signal timestamp to prevent duplicate Entry/Candle orders, including after restart. This priority does not bypass AND/OR, filters, or pending CHoCH. Older .set files must select the new switches instead of the old mask.
CHoCH is selected by EntryCHoCH, is valid during the following candle, and sends at most one request when conditions pass; see CHoCH Structure Entry. Signals read closed candles when a new EntryTimeframe bar appears: [1] is the latest closed candle, [2] the previous one. Cache lasts until the next EntryTimeframe candle; successfully processed bars are not reevaluated. Missing data, EMPTY_VALUE, or CopyBuffer errors temporarily return 0 without marking the bar processed, allowing retry on later ticks. Reverse and BB share EntryTimeframe. For Reverse BUY: BB SELL conflicts, BB BUY agrees, and BB=0 preserves BUY only under OR. Cached signals are not consumed after an order; avoiding duplicate evaluation is not the same as limiting each signal to one order. OpenOnNewCandle, trend filters, pause/license, limits, and the gateway still apply. OpenOnNewCandle=true permits one Entry per EntryTimeframe candle, including a later tick once data becomes available if no managed order has opened in that candle. DCA does not use Entry-source switches and retains its own DcaType and trend filters.
The dashboard lists enabled Entry sources in two columns, at most two per row, with separators. Panel height and SignalCombine/License positions adjust to the row count. The common timeframe appears in the Entry Signals heading; individual labels use Stoch Rev and BB. Candle is shown once when either Candle switch is enabled.
SelfAwareTrend auto presets: up to M5, Scalping (ATR 10, ER 14, band 1.5, SL 1.0 ATR); above M5 through H4, Default (14, 20, 2.0, 1.5); above H4, Swing (21, 30, 2.5, 2.0). Source is Close; default TQI combines ER/volume/structure/momentum, effective ATR, and smoothed asymmetric bands. BUY/SELL occurs only on a reversal in the latest closed candle. There is no score gate, self-learning, or trading timeout. Insufficient data waits and retries. AND/OR and existing Trend, Bias, Zone, time, spread, lot, limit, and DCA rules remain in force. Each SAT signal can attempt submission at most three times, at least five seconds apart within the current Entry candle. Retry only before broker submission or after a clear temporary rejection (requote, changed/unavailable prices, too many requests, or processing lock). Filled, pending, partially filled, or uncertain results such as timeout/disconnection remain locked against duplicates, including after restart. Unmet filters may wait within the same Entry candle. SAT does not add entries to an existing chain except under the current CHoCH rules.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| EntryStochastic | false | Enable the existing Stochastic source in AND/OR. | Retains MAIN/K comparison with 50. |
| EntryRSI | false | Enable RSI in AND/OR. | Retains RSI comparison with 50. |
| EntrySupertrend | false | Enable Supertrend in AND/OR. | Separate parameters are in the Supertrend group. |
| EntryCandle | true | Select Candle in AND/OR. | EntryCandle=true and UseCandleSignalForEntry=false starts a chain with Lot_First (Entry lots), without additional Candle orders in the chain. |
| EntryCHoCH | true | Select CHoCH in AND/OR. | Retains the existing pending mechanism and CHoCH processing priority. |
| EntryStochReverse | true | Select Stochastic Reverse in AND/OR. | Uses EntryTimeframe and separate thresholds; does not replace the existing Stochastic source. |
| EntryBollingerBands | true | Select Bollinger Bands in AND/OR. | Uses EntryTimeframe; a close outside a band is a signal. |
| EntrySelfAwareTrend | false | Enable SelfAwareTrend in the existing Entry combiner. | Independent of EntrySupertrend; preset selection uses EntryTimeframe, not the chart timeframe unless EntryTimeframe=CURRENT. |
| SignalCombine | OR | How participating signal directions are combined. | AND requires all signals to agree and none to be NONE. OR ignores NONE but returns NONE if BUY and SELL conflict. |
DCA
Add orders when price moves against the chain.
Processing logic: Each side maintains its own dcaCount, anchor, and progression. DcaType controls timing independently of OpenOnNewCandle: STEP_TF can open as soon as distance is met, at most one DCA per EntryTimeframe candle per side. STEP_CLOSE checks only at the start of a new candle and reevaluates all conditions. OpenOnNewCandle therefore affects only Entry/Candle/Bias. |CS, |BF, and |LB do not change the DCA anchor or lot progression. From DcaTrendFilterOrderCount onward, DCA must pass enabled trend filters.
ATR locks a separate BUY/SELL threshold after Entry/DCA or another chain order fills and positions update; a partial fill increasing volume also relocks it. It does not relock every tick/bar or simply because positions partially close. The dcaCount factor is locked along with the distance. |CS/|BF/|LB still do not increment dcaCount or change anchor rules. A flat chain clears the threshold. Restart, input changes, or taking over existing positions initializes it from the latest ATR[1] and current dcaCount. ATR errors, insufficient history, or nonpositive ATR block the side requiring a threshold, log once, and retry; no fixed-distance fallback is used. Anchor prices, BUY versus Ask, SELL versus Bid, lot sizes, filters, TP/SL, and gateway rules remain unchanged. DCA logs show ATR and the locked price threshold.
The dashboard hides Balance/Equity. The EA area shows DCA On/Off from UseDCA and STEP_TF/STEP_CLOSE/ATR mode. Step (price) is hidden, but distance calculation and locking still work as described. On indicates the feature is enabled, not that an order must open immediately; all trading gates still apply.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseDCA | true | Enable additional DCA orders. | false only manages existing orders. |
| DcaTrendFilterOrderCount | 1 | Existing progression-order count at which all trend filters begin applying to DCA; 0 disables DCA trend filtering. | With N=5, once the chain contains 5 progression orders (standard Entry + DCA, excluding |CS/|BF/|LB), the next DCA must pass trend filters. DCA does not use Entry-source switches. |
| DcaType | ATR | STEP_TF=0 and STEP_CLOSE=1 retain their behavior; ATR=2 uses locked ATR distance. | STEP_TF and ATR can open immediately on reaching distance, at most one DCA per EntryTimeframe candle per side. STEP_CLOSE checks only the new-candle tick. Closed-bar ATR calculates distance; it does not force waiting for a close to open. Multiply/Add/Manual LotMode is independent. |
| LotMode | MULTIPLY | Multiply, add, or use a manual list. | Candle does not participate in progression. |
| InitialMultiplier | 1.2 | Lot multiplier. | InitialLots × multiplier^count. |
| LotAddFactor | 0.01 | Lot increment in ADD mode. | Based on lastDcaLot, not Candle lots. |
| SingleOrderTPPips | 0 | Individual TP for each DCA order; 0 disables it. | Chain TP remains active. |
| ChainTPPips | 100 | Close the chain by distance from break-even (BE). | BE includes DCA/Candle/LB in the same chain. |
| ChainTPMoney | 0 | Close the chain by total monetary profit. | Candle profit is included. |
| DcaStepPips | 100 | Base pip distance in STEP_TF/STEP_CLOSE; base floor in ATR mode. | ATR price threshold = max(PipToPrice(DcaStepPips), ATR[1] × DcaATRMultiplier) × max(1,dcaCount). Example: price floor 1, ATR=2, multiplier=1.5, dcaCount=3 gives a threshold of 9 price units. ATR is not converted to pips again. ATR floor may be 0; the two older modes require >0 when DCA is enabled. |
| DcaATRPeriod | 14 | Separate DCA ATR period for DcaType=ATR; minimum 1. | Always uses EntryTimeframe, closed candle shift=1, and a separate handle from filters. |
| DcaATRMultiplier | 1.5 | Positive finite ATR multiplier, used only in ATR mode. | Base price distance = max(PipToPrice(DcaStepPips), ATR × DcaATRMultiplier). |
| UseCurrentDcaLotForEntry | false | Start a chain with its own base lot or inherit the opposite DCA level. | false: independent BUY/SELL from EffectiveInitialLot. true: max(EffectiveInitialLot, opposite.lastDcaLot). Does not change CandleSignalLot or BiasFilterLot. |
| UseTrendFilterScoring | true | Select SCORE or CONSENSUS. | false: panel shows ON/OFF and requires full consensus. true: Filter Combine shows direction and signed score, e.g. B SCORE +10/ Min +3, S SCORE -7/ Min -3, or N SCORE 0/ Min +3 for zero total. |
| EmaTrendScore | 2 | EMA Filter weight in SCORE mode. | BUY adds and SELL subtracts; 0 keeps EMA visible without contributing points. |
| MacdTrendScore | 1 | MACD Filter weight in SCORE mode. | Counted only when UseMacdFilter=true and the filter returns BUY or SELL. |
| BiasTrendScore | 2 | Bias Filter weight in SCORE mode. | Participates only when UseBiasFilterAsTrendFilter=true. |
| MarketStructureTrendScore | 2 | Market Structure weight in SCORE mode. | HH/HL and BOS BUY add points; LH/LL and BOS SELL subtract. CHOCH uses the new structure direction; neutral contributes nothing. |
| AdxTrendScore | 1 | ADX + DI weight in SCORE mode. | ADX must be strong enough; +DI/-DI determines the sign. |
| HtfAlignmentTrendScore | 2 | HTF Alignment weight in SCORE mode. | HTF EMA direction determines whether this weight is added or subtracted. |
| VwapTrendScore | 2 | VWAP weight in SCORE mode. | Price must be on the correct side of VWAP and slope must match the direction. |
| VolumeProfileTrendScore | 2 | Volume Profile Bias weight in SCORE mode. | Rising POC gives BUY; falling POC gives SELL, with price also on the correct side of POC. |
| TrendFilterMinScore | 3 | Minimum score in the trading direction. | With threshold 3, B SCORE +4/ Min +3 or S SCORE -4/ Min -3 passes; +2/-2 does not. B=BUY, S=SELL, N=neutral. The prefix indicates score direction, not confirmation of an opened order. |
Stepped multiplier (new multiplier by order count)
Change the multiplier by dcaCount.
Processing logic: Multipliers are compounded across historical tiers. A new tier affects only steps from its activation onward; the new multiplier is not raised to the entire previous dcaCount. This avoids abrupt lot jumps at tier changes.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseNewMultiplier | false | Enable the multiplier table. | false uses InitialMultiplier. |
| NewMultCount1 | 5 | dcaCount threshold for tier 1. | Set thresholds in increasing order. |
| NewMult1 | 1.5 | Multiplier at tier 1. | Can be reduced for deeper chains. |
| NewMultCount2 | 8 | dcaCount threshold for tier 2. | Set thresholds in increasing order. |
| NewMult2 | 1.3 | Multiplier at tier 2. | Can be reduced for deeper chains. |
| NewMultCount3 | 13 | dcaCount threshold for tier 3. | Set thresholds in increasing order. |
| NewMult3 | 1.2 | Multiplier at tier 3. | Can be reduced for deeper chains. |
| NewMultCount4 | 21 | dcaCount threshold for tier 4. | Set thresholds in increasing order. |
| NewMult4 | 1.15 | Multiplier at tier 4. | Can be reduced for deeper chains. |
| NewMultCount5 | 30 | dcaCount threshold for tier 5. | Set thresholds in increasing order. |
| NewMult5 | 1.1 | Multiplier at tier 5. | Can be reduced for deeper chains. |
Manual lot list
Fixed lot size for each DCA step.
Processing logic: Used only with LotMode=MANUAL. The first DCA uses element [0], the second [1]; after the list ends, the last value is retained. Candle/Bias/Balance do not use this list.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| ManualLotList | 0.01-0.01-0.01-0.02-0.02-0.02-0.03-0.03-0.04-0.04-0.05-0.05-0.06-0.06-0.07-0.07-0.08-0.08-0.09 | Lot values separated by hyphens (-). | Every value must be positive. |
Cross-chain pruning (Sniper)
Use recent winners to close older losing positions.
Processing logic: Closing occurs only when expected net profit reaches the threshold. Partial closing also depends on the broker volume step.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseSniper | true | Enable pruning. | Disable if you do not want automatic pruning. |
| SniperTriggerTotal | 15 | Minimum total order count. | Does not run below this threshold. |
| SniperFirstCount | 3 | Number of older losing orders. | Prioritizes older losers. |
| SniperLastCount | 5 | Number of recent winners; 0 selects automatically. | 0 avoids closing more than needed. |
| SniperMinProfit | 20 | Minimum net profit after closing. | In account currency. |
| UseTodayProfitForSniper | false | Include today's realized profit. | May reuse an already-realized profit budget. |
| UsePartialPrune | false | Allow partial closing of losing positions. | Depends on broker/account support. |
| PartialPruneMinLot | 0.01 | Minimum lot size for partial pruning. | Smaller positions are closed in full. |
| PartialPrunePct | 100 | Percentage of volume to prune. | 50 means half before volume normalization. |
Lot balance
Add exposure to the lighter side during drawdown.
Processing logic: An |LB order in the same chain contributes to BE/profit/TP but does not change the DCA anchor. It is blocked while trailing is CLOSING and does not open in the same tick as DCA.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseLotBalance | false | Enable lot balancing. | A hedging account is recommended. |
| LotBalanceMode | ADD_TO_CHAIN | Add to the same chain or use INDEPENDENT mode. | Independent mode uses a magic offset. |
| LB_LossPctTrigger | 30 | Drawdown percentage that triggers balancing. | Balance 10,000 with a 3,000 loss = 30%. |
| LB_LotDiffStart | 1.0 | Lot imbalance required to start. | BUY 2.0 / SELL 0.8 gives a difference of 1.2. |
| LB_LotDiffStop | 0.2 | Lot imbalance at which balancing stops. | Set below the start threshold. |
| LB_AddLot | 0.2 | Volume added per step. | Adds to the lighter side. |
| LB_DelaySeconds | 10 | Delay after each balancing order. | Reduces clustered entries. |
| LB_NegLotsPct | 70 | Percentage of lots currently losing. | Confirmation condition. |
| LB_LossOrdersCount | 1 | Minimum number of losing orders. | At least one. |
| LB_MagicOffset | 99999 | Magic offset for Independent mode. | Avoid overlap with other EAs. |
Trailing (DCA chain)
Virtual trailing relative to chain break-even.
Processing logic: Each BUY/SELL chain has DISARMED → ARMED → CLOSING states. When gain from BE reaches TrailStartPips, the first stop locks TrailFirstSLBufferPips. Each additional TrailStepPips of best gain raises the locked level by exactly one step. Changes in chain count/lot/BE reset trailing. During CLOSING, the EA blocks further entries on that side and retries closing until the chain is empty.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseChainTrailing | false | Enable chain trailing. | The EA panel shows Trailing above Sniper: Off when disabled; when enabled, B (BUY) and S (SELL) have separate states: Wait=not armed, Active=trailing armed, Closing=closing the chain. Green when a side is Active, orange when a side is Closing. This is trailing status, not the EA's permission to trade. |
| TrailStartPips | 150 | Profit distance from BE required to arm trailing. | BUY example from the source guide: Bid ≥ BE + 15p; use the EA's pip convention for TrailStartPips. |
| TrailStepPips | 50 | Stop-tightening step. | Moves only in the favorable direction. |
| TrailFirstSLBufferPips | 20 | Initial locked profit distance. | Set below TrailStartPips. |
| TrailOverridesChainTP | true | Bypass Chain TP once trailing owns the chain. | true: from arming eligibility onward, trailing takes over and ChainTPPips/ChainTPMoney do not close the chain. false: Chain TP can still close before trailing. |
| UseBrokerTrailSL | false | Mirror the virtual stop to broker SL. | Provides protection during disconnection. |
Close by money
Money-based exits and account/time-level locks.
Processing logic: Money-based exits close the entire managed footprint; Weekend uses server time. Daily limits use realized plus floating P/L and stay latched until the new trading day plus the configured delay.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| MoneyTPAll | 0 | Total profit threshold to close all managed positions; 0 disables. | In account currency. |
| MoneySLAll | 0 | Total loss threshold to close all managed positions; 0 disables. | Must be negative when enabled. |
Weekend close
Pre-weekend closing and time-based controls.
Processing logic: Money-based exits close the entire managed footprint; Weekend uses server time. Daily limits use realized plus floating P/L and stay latched until the new trading day plus the configured delay.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseWeekendClose | false | Close before the weekend. | If managed positions remain, sends one push notification and audible Alert within the 10 minutes before WeekendCloseTime in server time. Checked in both OnTimer and OnTick. |
| WeekendCloseTime | 20:45:00 | Closing time in server time. | Set sufficiently before market close. The alert window starts 10 minutes before WeekendCloseTime. |
Daily profit target
Daily profit/loss limits in money or as a percentage of account balance when the trading day is initialized.
Processing logic: Money-based exits close the entire managed footprint; Weekend uses server time. Daily limits use realized plus floating P/L and stay latched until the new trading day plus the configured delay. Percentage limits use the saved starting daily balance, not intraday equity or balance changes. On first attachment, use balance at initialization; restarts within the day reuse the saved base. A new base is fixed on the next server-time trading day after NewDayDelayMinutes. P/L is realized profit for the day plus floating P/L of EA-managed trades on the symbol under the current MagicNumber rules, not total P/L from every EA/symbol in the account. Reaching a limit closes orders through the existing protection flow and locks Entry/DCA until the new day; unfinished closes continue to be processed. With money and percentage thresholds enabled together, whichever is reached first triggers. If the base balance is nonpositive, percentage thresholds do not apply, but monetary limits remain active.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| DailyProfitTarget | 0 | Daily monetary profit target. | 0 disables. If percentage limits are also enabled, the first money or percentage threshold reached triggers. |
| DailyLossLimit | 0 | Daily monetary loss limit. | Must be negative or 0. If percentage limits are also enabled, the first money or percentage threshold reached triggers. |
| DailyProfitTargetPct | 0 | Daily TP as a percentage of starting daily balance; positive value, 0 disables. | With a 1,000 USD base, 5 means +50 USD. If DailyProfitTarget=30, the EA stops already at +30 USD. |
| DailyLossLimitPct | 0 | Daily SL as a percentage of starting daily balance; positive value, 0 disables. | With a 1,000 USD base, 3 means -30 USD. Unlike this percentage input, monetary DailyLossLimit must be negative. Values above 100% are allowed; there is no hard 100% cap. |
| NewDayDelayMinutes | 120 | Delay before releasing the daily latch on a new day. | Helps avoid rollover. |
Stochastic Entry
Independently enabled Entry sources.
Processing logic: Signals read closed candles and cache results on EntryTimeframe. Stochastic >50 gives BUY, <50 gives SELL; RSI >50 gives BUY, <50 gives SELL. Supertrend returns the current trend direction.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| StochKPeriod | 8 | Stochastic K period. | Fast configuration. |
| StochDPeriod | 3 | Stochastic D period. | Fast configuration. |
| StochSlowing | 3 | Stochastic slowing period. | Fast configuration. |
| StochMaMethod | SMA | Stochastic moving-average method. | MQL5 enum. |
| StochPrice | LOWHIGH | Stochastic price field. | MQL5 enum. |
| StochOverbought | 80 | Stochastic overbought threshold. | Currently not used by Signal_Stoch; Entry direction is compared with 50. |
| StochOversold | 20 | Stochastic oversold threshold. | Currently not used by Signal_Stoch; Entry direction is compared with 50. |
Stochastic Reverse Entry
Enable EntryStochReverse. BUY: K[2] < oversold threshold and K[1] >= threshold. SELL: K[2] > overbought threshold and K[1] <= threshold. Uses MAIN/K only, not a K/D crossover; the original Stochastic source is unchanged.
Processing logic: Only closed candles are read when a new EntryTimeframe candle appears: [1] is the latest closed bar, [2] the previous bar. Results remain cached until the next EntryTimeframe bar; successfully processed bars are not reread. Missing data, EMPTY_VALUE, or CopyBuffer errors temporarily return 0 without marking the bar processed, so the next tick can retry. AND requires all enabled sources to have the same nonzero direction. OR ignores 0 but returns 0 for simultaneous BUY and SELL. Reverse and BB share EntryTimeframe. Example: Reverse BUY with BB SELL conflicts; BB BUY agrees; with BB=0, only OR can retain BUY. Cache is not consumed after an order: avoiding duplicate evaluation is not a one-order-per-signal limit. Every order still passes OpenOnNewCandle on EntryTimeframe, trend filters, pause/license, limits, and the gateway. OpenOnNewCandle=true limits Entry to one order per EntryTimeframe candle; a later tick may enter once data becomes available if no managed order opened in that candle. DCA does not use Entry-source switches or these two sources; its DcaType and trend filters remain unchanged.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| StochReverseKPeriod | 8 | Separate K period, minimum 1. | Does not change the existing StochKPeriod. |
| StochReverseDPeriod | 3 | D period passed to iStochastic, minimum 1. | D does not participate in BUY/SELL conditions. |
| StochReverseSlowing | 3 | K slowing, minimum 1. | Affects the MAIN/K line. |
| StochReverseMaMethod | SMA | Stochastic Reverse MA method. | ENUM_MA_METHOD enum. |
| StochReversePrice | LOWHIGH | Price field for Stochastic Reverse. | ENUM_STO_PRICE enum. |
| StochReverseOversold | 20 | Oversold threshold; 0 <= Oversold < Overbought <= 100. | 19 → 20 gives BUY; 20 → 21 does not. |
| StochReverseOverbought | 80 | Separate overbought threshold. | 81 → 80 gives SELL; 80 → 79 does not. |
Bollinger Bands Entry
Enable EntryBollingerBands. BUY when Close[1] < LowerBand[1]; SELL when Close[1] > UpperBand[1]. Equality with a band gives no signal. Each closed bar outside a band is evaluated anew; no crossover or reentry into the bands is required. Band shift is always 0.
Processing logic: Only closed candles are read when a new EntryTimeframe candle appears: [1] is the latest closed bar, [2] the previous bar. Results remain cached until the next EntryTimeframe bar; successfully processed bars are not reread. Missing data, EMPTY_VALUE, or CopyBuffer errors temporarily return 0 without marking the bar processed, so the next tick can retry. AND requires all enabled sources to have the same nonzero direction. OR ignores 0 but returns 0 for simultaneous BUY and SELL. Reverse and BB share EntryTimeframe. Example: Reverse BUY with BB SELL conflicts; BB BUY agrees; with BB=0, only OR can retain BUY. Cache is not consumed after an order: avoiding duplicate evaluation is not a one-order-per-signal limit. Every order still passes OpenOnNewCandle on EntryTimeframe, trend filters, pause/license, limits, and the gateway. OpenOnNewCandle=true limits Entry to one order per EntryTimeframe candle; a later tick may enter once data becomes available if no managed order opened in that candle. DCA does not use Entry-source switches or these two sources; its DcaType and trend filters remain unchanged.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| BollingerPeriod | 20 | Bollinger period, minimum 1. | Shift is fixed at 0; there is no shift input. |
| BollingerDeviation | 2.0 | Standard-deviation multiplier; must be finite and >0. | Default is 2.0. |
| BollingerPrice | CLOSE | Applied price for calculating BB bands. | Comparison always uses Close[1], even with PRICE_TYPICAL selected for band calculation. |
RSI Entry
Independently enabled Entry sources.
Processing logic: Signals read closed candles and cache results on EntryTimeframe. Stochastic >50 gives BUY, <50 gives SELL; RSI >50 gives BUY, <50 gives SELL. Supertrend returns the current trend direction.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| RsiPeriod | 14 | RSI period. | Uses closed candles. |
| RsiPrice | CLOSE | RSI applied price. | Uses closed candles. |
| RsiOverbought | 70 | RSI overbought threshold. | Currently not used by Signal_RSI; Entry direction is compared with 50. |
| RsiOversold | 30 | RSI oversold threshold. | Currently not used by Signal_RSI; Entry direction is compared with 50. |
Supertrend Entry
Independently enabled Entry sources.
Processing logic: Signals read closed candles and cache results on EntryTimeframe. Stochastic >50 gives BUY, <50 gives SELL; RSI >50 gives BUY, <50 gives SELL. Supertrend returns the current trend direction.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| SupertrendAtrPeriod | 12 | Supertrend ATR period. | A larger value smooths the calculation. |
| SupertrendMultiplier | 3.5 | Band width multiplier. | A larger value reduces direction flips. |
CHoCH Structure Entry
CHoCH Entry uses the same detector as chart drawings on EntryTimeframe.
Processing logic: Enable EntryCHoCH to select CHoCH. Other source switches combine through AND/OR; Candle participates when EntryCandle or UseCandleSignalForEntry is true. Swings are confirmed after N closed bars on each side; equal highs/lows are not strict swings. The first swing is H/L; later swings are HH/HL/LH/LL. In bearish LH+LL structure, a close above the protected LH creates Bullish CHoCH. In bullish HH+HL structure, a close below the protected HL creates Bearish CHoCH. A wick through the level or a close exactly at it is not a break. A same-direction break is BOS. After CHoCH, a new structural pair is required before the next event. Each level fires once.
Entry is evaluated from the first tick of the next candle; the signal remains valid through that candle if filters initially block it. It can enter when same-side positions already exist. Entry lots, First SL/TP, Magic, and existing limits still apply. Each signal submits at most one request; once submitted, even if rejected or pending at the broker, it is not resubmitted. While CHoCH is pending, the Engine does not open accompanying Candle/Bias/DCA orders; afterward DCA retains its own price steps. Experts logs explain blocked entries. This EA version does not include Smart Grid/CHoCH Cooldown.
CHoCH arrows are signals; Entry labels come only from executed deals at their actual time/price. Restarting or missing multiple candles only reconstructs historical drawings, without replaying trades. Objects use a dedicated prefix, with at most 3,000 objects and 3,000 recent deals within the history window.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| ChochSwingLookback | 5 | Closed candles required on each side to confirm a swing; 1–100. | N=5 means the swing is known only after the fifth candle on the right closes. |
| ChochHistoryBars | 500 | Closed candles used to build structure, independent of displayed candle count. | From 2 × lookback + 4 to 5000. Keep enough history to identify structure. |
| ShowChochSwings | true | Show swing markers and structure labels. | Disabling only hides drawings; it does not disable selected CHoCH Entry. |
| ShowChochBOS | true | Show continuation BOS segments. | Horizontal segments end at the breakout candle; no infinite rays. |
| ShowChochSignals | true | Show CHoCH lines and BUY/SELL signal arrows. | BUY below the confirmation candle, SELL above. An arrow does not mean an order exists. |
| ShowChochEntries | true | Show Entry BUY/SELL from executed CHoCH deals. | Blocked or rejected orders have no Entry label. Partial fills show each deal. |
| ChochSwingHighColor | clrOrange | Swing High marker and label color. | Default Orange. |
| ChochSwingLowColor | clrDodgerBlue | Swing Low marker and label color. | Default DodgerBlue. |
| ChochBullishColor | clrBlue | BUY structure, signal, and entry color. | Default Blue. |
| ChochBearishColor | clrRed | SELL structure, signal, and entry color. | Default Red. |
Confirmed candle signal
Closed-candle patterns combined with trend, support/resistance, confirmation, ATR, and scoring.
Processing logic: Patterns are detected on EntryTimeframe. Combined entries with matching SelfAwareTrend and UseSelfAwareAutoSLTP=true prioritize SAT SL/TP. For other Candle entries, FirstSLPips>0 always takes priority. With FirstSLPips=0 and UseAutoCandleStopLoss=true, use structural SL on TrendTimeframe; with FirstSLPips=0 and Auto SL=false, submit SL=0. |CS contributes to shared BE/profit/TP but not DCA progression. When UseCandleSignalForEntry=false and Candle is selected for Entry, orders use Entry lots without |CS. When true, Engine_CandleLot prioritizes the active time-window lot; otherwise it uses CandleSignalLot and its zero fallback. Lot caps still apply.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseCandleSignal | true | Allow Candle module initialization and analysis; not a master switch blocking Candle trades. | Even when false, analysis and entries may occur if EntryCandle or UseCandleSignalForEntry is enabled. NotifyCandleSignal/NotifyCandleSignalDetection can also keep analysis active. To stop Candle trading, set both EntryCandle=false and UseCandleSignalForEntry=false. Enabling UseCandleSignal alone does not authorize entries. |
| UseCandleSignalForEntry | false | true uses Candle lots and allows additional Candle orders in a chain; false uses Entry lots when EntryCandle=true. | true prioritizes Candle logic/lots whether EntryCandle is on or off, adding only one Candle source to AND/OR. false enters from Candle only if EntryCandle=true, using Entry lots with no additional Candle entries. Both false leaves only analysis/display if the corresponding options are enabled. |
| NotifyCandleSignal | false | Send Push and Alert after a Candle order opens successfully. | No notification for drawings alone or signals blocked by the combiner/trading gates. Uses the order's actual Entry/SL/TP. |
| NotifyCandleSignalDetection | false | Send Push and Alert when a valid Candle signal is detected and drawn. | Independent of NotifyCandleSignal. Both enabled gives a SIGNAL notification on detection and an ORDER notification if the trade subsequently opens. |
| CandleSignalLot | 0.2 | Candle lot size; 0 uses InitialLots. | Capped by MaxLots; the first Candle order uses First TP/SL. |
| UseAutoCandleStopLoss | false | Automatically set a separate structural SL for Candle orders. | Used only when FirstSLPips=0. With FirstSLPips>0, fixed SL always has priority over Auto SL. |
| CandleStopLossATRBuffer | 0.25 | ATR(14) buffer beyond structural invalidation. | BUY: SL = lowest low − buffer × ATR; SELL: SL = highest high + buffer × ATR. The source guide notes 0.10–0.30 can help reduce wick-triggered stops. |
| CandleStopLossSwingLookback | 12 | TrendTimeframe candles used to find the nearest confirmed swing. | Combines the signal cluster boundary (up to 3 candles) with the nearest swing low/high, choosing the farther protective boundary. Minimum 3. |
| MinConfidenceScore | 70 | Minimum signal score. | 35 pattern + 25 support/resistance + 20 trend + 15 confirmation + 5 volume. |
Self-Aware Trend Entry
Draw the SelfAwareTrend line and show SL, TP1, TP2, and TP3 for open SelfAware Auto SL/TP positions. Configure trend colors and automatic risk levels. This is an adaptive SuperTrend reversal source, not a SATS dashboard.
Processing logic: Drawings use the same formula and EntryTimeframe presets, but maintain independent state and neither generate nor consume trading signals. TP/SL level display does not place or modify orders, is independent of ShowSelfAwareTrend, and continues showing older Auto trades after the Entry source is disabled. Trend colors apply when ShowSelfAwareTrend=true and do not change entries or SL/TP.
SelfAwareTrend auto presets: up to M5, Scalping (ATR 10, ER 14, band 1.5, SL 1.0 ATR); above M5 through H4, Default (14, 20, 2.0, 1.5); above H4, Swing (21, 30, 2.5, 2.0). Source is Close; default TQI combines ER/volume/structure/momentum, effective ATR, and smoothed asymmetric bands. BUY/SELL occurs only on a reversal in the latest closed candle. There is no score gate, self-learning, or trading timeout. Insufficient data waits and retries. AND/OR and existing Trend, Bias, Zone, time, spread, lot, limit, and DCA rules remain in force. Each SAT signal can attempt submission at most three times, at least five seconds apart within the current Entry candle. Retry only before broker submission or after a clear temporary rejection (requote, changed/unavailable prices, too many requests, or processing lock). Filled, pending, partially filled, or uncertain results such as timeout/disconnection remain locked against duplicates, including after restart. Unmet filters may wait within the same Entry candle. SAT does not add entries to an existing chain except under the current CHoCH rules.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| ShowSelfAwareTrend | false | Toggle the SelfAwareTrend chart line independently of EntrySelfAwareTrend. | true draws up to 300 recent closed EntryTimeframe candles, colored by SelfAwareBullColor/SelfAwareBearColor (green up, red down by default), with gaps at reversals. No current-candle values are drawn. Timer updates continue while paused if the license is valid; missing data waits and retries. false or EA removal deletes the module's line segments. Can be used for observation without SAT Entry; chart timeframe does not change presets unless EntryTimeframe=CURRENT. |
| ShowSelfAwareTPSLLevels | false | Show horizontal SL/TP lines and price labels for open AwareTrend Auto trades. | Red SL is the current broker SL and follows trailing. Green TP1/TP2/TP3 share the partial-close cache, using actual volume-weighted fill price and initial SL restored from history. All three remain for reference after partial closure. Labels include ticket and BUY/SELL. Timer updates roughly every second with a valid license; lines are deleted on close, input disable, or EA removal. No hypothetical levels without a position; missing history waits rather than guessing TP. Does not affect MT5 Show trade levels. |
| SelfAwareBullColor | clrLimeGreen | SelfAwareTrend line color in an uptrend. | Default LimeGreen; choose in Inputs. |
| SelfAwareBearColor | clrTomato | SelfAwareTrend line color in a downtrend. | Default Tomato; use the Bull color for a single-color line. |
| UseSelfAwareAutoSLTP | false | For entries with matching SAT, replace FirstSLPips/FirstTPPips and Auto Candle SL with pivot ± effective ATR SL; TP1=1R, TP2=2R, TP3=3R. | BUY SL is below both pivot low minus buffer and signal Close minus buffer; SELL is symmetric. At submission, provisional SL/TP3 uses Ask/Bid. After fills, R is measured from volume-weighted fill price to the initial SL in order history. TP1/TP2/TP3 are normalized to tick size; broker TP3 is synchronized and retried if modification is temporarily disallowed. Additional partial fills update average price and initial volume; trailing or partial closures do not change R. Skip entry if price has passed SL. SL and TP3 are sent to the broker; TP1/TP2 require the EA running. Each target aims to close one-third of initial volume, rounded to lot step, with the remainder at TP3. Example: 0.04 lots and 0.01 step gives 0.01 / 0.01 / 0.02. Volumes too small to split carry over to later targets. Fill price, initial SL, targets, and initial volume share a cache for closing/drawing; history is reread only after trade/volume changes or when unavailable. Progress is restored from deal history after restart; existing Auto trades remain managed even after the input is disabled. Requires a hedging account. SL does not automatically move to break-even. Existing trailing, chain TP, money exits, and pruning can close earlier. Gaps may close multiple portions at current prices, with no guarantee of exact 1R/2R/3R fills. Applies only to combined entries with SAT, not DCA or separate Bias/Candle entries. |
EMA trend filter
Filter Entry/DCA/Candle using two EMAs.
Processing logic: Inside the time window, EMA1>EMA2 allows only BUY and EMA1<EMA2 only SELL for Entry, Candle, and DCA once the filtering threshold is reached. Outside the window, the filter is inactive.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseEmaFilter | true | Enable the shared EMA filter. | Candle has no separate EMA filter. |
| ShowEmaOnChart | false | Draw EMA 1 and EMA 2 in the main price window. | Visible only when chart timeframe matches TrendTimeframe. Changing away removes them; changing back redraws them. |
| EmaPeriod1 | 34 | Manual fast EMA period; defaults come from the current configuration. | Directly effective only when TrendStrategySuggestion=NONE. |
| EmaPeriod2 | 89 | Manual slow EMA period; defaults come from the current configuration. | Directly effective only when TrendStrategySuggestion=NONE. |
| EmaPeriod1Color | clrDodgerBlue | EMA 1 line color. | Color does not affect trend logic; change it in Inputs. |
| EmaPeriod2Color | clrOrangeRed | EMA 2 line color. | Color does not affect trend logic; change it in Inputs. |
| UseEmaTimeWindow | false | Restrict the EMA filter to a time window. | false applies it at all times. |
| EmaWindowStart | 11:00:00 | Local-time EMA window start. | Neutral outside the window. |
| EmaWindowEnd | 21:00:00 | Local-time EMA window end. | Neutral outside the window. |
MACD trend filter
Filter Entry/DCA/Candle using MACD main/signal.
Processing logic: Main>signal permits only BUY; main<signal only SELL. FlipGuard removes small oscillations around crossovers.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseMacdFilter | true | Enable the shared MACD filter. | Can be combined with EMA. |
| ShowMacdOnChart | false | Show MACD in a separate chart subwindow. | Visible only when chart timeframe matches TrendTimeframe. Changing away removes it; changing back redraws it. |
| MacdFastEma | 12 | Manual MACD fast EMA period; BALANCED defaults are 12/26/9. | Directly effective in NONE; Fast must be less than Slow. |
| MacdSlowEma | 26 | Manual MACD slow EMA period; BALANCED defaults are 12/26/9. | Directly effective in NONE; Fast must be less than Slow. |
| MacdSignalSma | 9 | Manual MACD signal SMA period; BALANCED defaults are 12/26/9. | Directly effective in NONE; Fast must be less than Slow. |
| MacdPrice | CLOSE | Applied price. | Uses closing price. |
| MacdFlipGuard | 0 | Minimum main-signal distance. | 0 disables the guard. |
| UseMacdTimeWindow | false | Restrict MACD to a time window. | Neutral outside the window. |
| MacdWindowStart | 11:00:00 | Local-time MACD window start. | Can differ from the EMA window. |
| MacdWindowEnd | 21:00:00 | Local-time MACD window end. | Can differ from the EMA window. |
Additional trend filters
ADX + DI, Market Structure, HTF Alignment, and additional trend filters.
Processing logic: Each filter is enabled separately and returns BUY (+1), SELL (-1), or NEUTRAL (0). Market Structure distinguishes HH/HL, LH/LL, BOS, and CHOCH; CHOCH returns the new reversal direction. VWAP and Volume Profile use closed TrendTimeframe candles. Volume Profile uses broker tick volume, not centralized market-wide volume. Disabled filters participate in neither CONSENSUS nor SCORE.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseAdxFilter | true | Enable ADX + DI on TrendTimeframe. | ADX below the threshold returns neutral; +DI>-DI gives BUY and -DI>+DI gives SELL. |
| AdxPeriod | 14 | Manual ADX period; BALANCED defaults are 14/22 for period/strength. | The source guide describes strength thresholds around 20–25 for filtering weak markets. |
| AdxMinStrength | 22.0 | Manual minimum ADX strength; BALANCED period/strength defaults are 14/22. | Thresholds around 20–25 are described for filtering weak markets. |
| UseMarketStructureTrendFilter | true | Enable HH/HL or LH/LL filtering. | The latest two swing highs and swing lows must confirm the same direction. |
| MarketStructureLookback | 80 | Manual structure lookback; BALANCED defaults are 80/3 for lookback/strength. | Higher swing strength reduces noise but responds more slowly. |
| MarketStructureSwingStrength | 3 | Manual swing strength; BALANCED defaults are 80/3 for lookback/strength. | Higher strength reduces noise but responds more slowly. |
| UseHtfAlignmentFilter | true | Enable EMA confirmation on HigherTimeframe. | Fast>Slow gives BUY; Fast<Slow gives SELL. |
| HtfAlignmentFastEma | 50 | Manual fast HTF EMA; BALANCED defaults are 50/200. | Independent of Bias Filter EMAs. |
| HtfAlignmentSlowEma | 200 | Manual slow HTF EMA; BALANCED defaults are 50/200. | Independent of Bias Filter EMAs. |
| UseVwapTrendFilter | true | Enable VWAP Trend Filter on TrendTimeframe. | BUY requires a close above rolling VWAP and sufficient upward VWAP slope; SELL uses the opposite conditions. |
| VwapLookbackBars | 50 | Closed candles used for rolling VWAP. | VWAP uses typical price × tick volume; a longer lookback is steadier but slower. |
| VwapMinSlopeATR | 0.02 | Minimum VWAP slope as a fraction of ATR. | Filters out nearly flat VWAP; 0 allows any slope with the correct sign. |
| UseVolumeProfileBias | true | Enable Volume Profile Bias using broker tick volume. | Compares POC in the recent half of the period with the earlier half, and price with the current POC. |
| VolumeProfileLookbackBars | 120 | Total closed candles in Volume Profile. | The EA splits the lookback in half to determine whether POC is shifting up or down. |
| VolumeProfileBins | 48 | Number of price buckets for allocating tick volume. | 10–200; more bins give detail but increase sensitivity and computation. |
Higher timeframe Bias Filter
Top-down Bias and points of interest from closed HigherTimeframe candles. Entry filtering is separate from opening orders at Key Levels.
Processing logic: UseBiasFilter enables Bias/Key Level analysis. UseBiasFilterAsTrendFilter decides whether results gate Entry/Candle/DCA; UseBiasFilterForEntry controls independent |BF orders at Key Levels. Levels are recalculated only after a new HigherTimeframe candle closes. Rectangles are translucent; overlapping green and red/orange regions can look purple. This is overlap/conflict, not a separate signal.
UseTrendFilterForBiasEntry adds a separate HigherTimeframe trend confirmation for standard Entry, Candle, and Bias. It uses SCORE when UseTrendFilterScoring=true, otherwise CONSENSUS. Bias does not score itself in the HTF score, avoiding a loop. |BF contributes to shared BE/profit/TP but does not change DCA progression.
Automatic mode uses broker server days and resets on the first tick of a new day. Reading D1 High-Low lets it reactivate after restart if the current day already exceeded the threshold. If D1 data is unavailable, it does not newly activate and retries on later ticks; a state already ON stays ON until the day ends. Applies to standard Entry/Candle/Bias, not DCA. The dashboard shows AUTO ON/OFF.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseBiasFilter | true | Enable Bias and Key Level analysis, panel, and rectangles. | false disables analysis, hides the panel/rectangles, and disables both the trend gate and |BF orders. |
| UseBiasFilterAsTrendFilter | false | Use Bias as a gate for Entry, Candle, and DCA. | false removes Bias/Key Level checks from these entries while keeping the panel and rectangles visible. |
| UseBiasFilterForEntry | false | Allow Bias to open orders at Key Levels. | Requires UseBiasFilter=true; at most one order per direction per closed HTF candle. |
| UseTrendFilterForBiasEntry | false | Add HigherTimeframe trend filtering to Entry, Candle, and Bias entries. | ON requires both ordinary TrendTimeframe and HTF trend checks; DCA does not use this HTF gate. The Bias panel shows direction and SCORE/MIN. With UseAutoTrendFilterForBiasEntry=true, automatic mode controls the actual state without rewriting this manual input. |
| UseAutoTrendFilterForBiasEntry | false | Automatically control the HTF trend filter from the symbol's daily range. | true overrides manual control by UseTrendFilterForBiasEntry: OFF at the start of the day, ON for the rest of the day once High-Low exceeds the threshold. false uses the manual switch. |
| BiasTrendDailyRangeThreshold | 100.0 | Current D1 High-Low threshold in direct price units, not pips/points. | With threshold 100: Low=3300, High=3400 does not enable it; High=3400.01 does. Must be >0. |
| BiasFilterLot | 0.2 | Separate Bias order lot size. | 0 uses InitialLots; positive values are normalized/capped by broker rules and MaxLots. |
| BiasLookbackBars | 150 | Closed HTF candles used for analysis. | Does not use shift 0. |
| SwingStrengthBars | 3 | Bars required on each side to confirm a swing. | Higher values detect larger/slower swings. |
| MaxKeyLevels | 6 | Number of highest-scoring levels retained. | Range 1–20. |
| BiasFastEMAPeriod | 50 | Separate fast EMA for HTF Bias. | Fast must be less than Slow. |
| BiasSlowEMAPeriod | 200 | Separate slow EMA for HTF Bias. | Fast must be less than Slow. |
| ShowKeyLevelsOnChart | true | Draw Key Level rectangles. | Default colors: support green, resistance deep pink, bullish FVG blue, bearish FVG orange, liquidity gold, BUY green, SELL red. All are configurable through color inputs. |
| ShowBiasSupport | true | Show/hide Support on the chart and Bias panel. | Display only; levels still participate in trading logic. |
| BiasSupportColor | clrSeaGreen | Support zone color. | Change directly in Inputs. |
| ShowBiasResistance | true | Show/hide Resistance on the chart and Bias panel. | Uses BiasResistanceColor when enabled. |
| BiasResistanceColor | clrDeepPink | Resistance zone color. | Default deep pink. |
| ShowBiasBullishFvg | true | Show/hide Bullish FVG. | Uses BiasBullishFvgColor. |
| BiasBullishFvgColor | clrDodgerBlue | Bullish FVG color. | Display only. |
| ShowBiasBearishFvg | true | Show/hide Bearish FVG. | Uses BiasBearishFvgColor. |
| BiasBearishFvgColor | clrOrange | Bearish FVG color. | Display only. |
| ShowBiasLiquidity | true | Show/hide Liquidity High/Low. | Both use BiasLiquidityColor. |
| BiasLiquidityColor | clrGold | Liquidity High/Low color. | Shared by both liquidity types. |
| ShowBiasBuyZone | true | Show/hide bullish OB, Fibonacci discount, and other BUY zones. | Uses BiasBuyZoneColor. |
| BiasBuyZoneColor | clrSeaGreen | Color of other BUY zones. | Bullish OB, Fibonacci discount, and other BUY levels. |
| ShowBiasSellZone | true | Show/hide bearish OB, Fibonacci premium, and other SELL zones. | Uses BiasSellZoneColor. |
| BiasSellZoneColor | clrTomato | Color of other SELL zones. | Bearish OB, Fibonacci premium, and other SELL levels. |
Zone Cycle filter
Restrict Entry using four manual or AI zone boundaries.
Processing logic: A zero boundary is unrestricted; even a single nonzero boundary has logic and a line. Disabling Zone or an API failure clears the zones and fails open, without reusing stale data.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseZoneCycle | false | Enable the zone filter. | false removes zone lines. |
| UseZoneCycleByAI | false | Choose AI or manual zones. | Manual lines can be dragged. |
| BuyZoneUpper | 0 | Upper BUY boundary. | 0 leaves this boundary unrestricted. |
| BuyZoneLower | 0 | Lower BUY boundary. | 0 leaves this boundary unrestricted. |
| SellZoneUpper | 0 | Upper SELL boundary. | Only the latest line is retained. |
| SellZoneLower | 0 | Lower SELL boundary. | Only the latest line is retained. |
| ZoneAiApiKey | empty | Gemini API key. | Do not share presets containing the key. |
| ZoneAiModel | gemini-3.6-flash | API model identifier. | An incorrect model may return 404. |
| ZoneAiTimeoutMs | 30000 | Timeout in milliseconds. | Increase for slow networks. |
| ZoneAiBarCount | 48 | HTF candles sent to AI. | More candles increase payload size. |
New Cycle (disable entries at specific time)
Scheduled New Cycle locks and pending-order control on the chart symbol.
Processing logic: The EA scans pending orders in OnTick/OnTimer, identifies commands by both order type and price, executes them, then deletes the pending order. New Cycle OFF blocks only new chains; existing chains remain managed and can receive DCA. Stop Buy/Sell blocks all additional orders in the corresponding direction. State persists across restarts.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseNewCycle | true | Enable the scheduled cycle lock. | false ignores the schedule. |
| NewCycleDay | FRIDAY | Day to lock new cycles. | Uses server time. |
| NewCycleOffTime | 17:00:00 | Time to lock new cycles. | HH:MM:SS. |
Time limit (local PC time)
Entry opening windows in local PC time.
Processing logic: Entry is within hours if it falls inside at least one enabled window. AllowDcaOutsideHours may allow DCA management of an existing chain outside those windows.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseTimeLimit | false | Enable time limits. | false allows all hours. |
| UseTimeWindow1 | true | Enable window 1. | Can cross midnight. |
| Window1Start | 01:00:00 | Window 1 start. | Local PC time, HH:MM:SS. |
| Window1End | 11:30:00 | Window 1 end. | Local PC time, HH:MM:SS. |
| UseTimeWindow2 | false | Enable window 2. | Can cross midnight. |
| Window2Start | 14:30:00 | Window 2 start. | Local PC time, HH:MM:SS. |
| Window2End | 18:30:00 | Window 2 end. | Local PC time, HH:MM:SS. |
| UseTimeWindow3 | false | Enable window 3. | Can cross midnight. |
| Window3Start | 20:30:00 | Window 3 start. | Local PC time, HH:MM:SS. |
| Window3End | 23:30:00 | Window 3 end. | Local PC time, HH:MM:SS. |
| UseTimeWindow4 | false | Enable window 4. | Can cross midnight. |
| Window4Start | 02:30:00 | Window 4 start. | Local PC time, HH:MM:SS. |
| Window4End | 05:30:00 | Window 4 end. | Local PC time, HH:MM:SS. |
| AllowDcaOutsideHours | true | Allow DCA outside trading hours. | Does not open new chains. |
Trade sessions
Session information on the dashboard.
Processing logic: Does not replace Time Limit. Real sessions use UTC/DST; custom sessions use server time.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| UseSessionInfo | true | Enable session information. | Disabling reduces UI information. |
| UseRealMarketSessions | true | Use real sessions with daylight-saving adjustments. | false uses custom hours. |
| TokyoStartHour | 2 | Custom Tokyo start hour in server time. | Used only when UseRealMarketSessions=false. |
| LondonStartHour | 9 | Custom London start hour in server time. | Used only when UseRealMarketSessions=false. |
| NewYorkStartHour | 14 | Custom NewYork start hour in server time. | Used only when UseRealMarketSessions=false. |
| SydneyStartHour | 21 | Custom Sydney start hour in server time. | Used only when UseRealMarketSessions=false. |
Remote control (pending orders)
Control the EA with pending orders on the chart symbol and scheduled New Cycle locks.
Processing logic: The EA scans pending orders in OnTick/OnTimer, identifies commands by both order type and price, executes them, then deletes the pending order. New Cycle OFF blocks only new chains; existing chains remain managed and can receive DCA. Stop Buy/Sell blocks all additional orders in the corresponding direction. State persists across restarts.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| RemotePausePrice | 999999 | BUY STOP at this price pauses the EA. | The EA recognizes and deletes the pending order. |
| RemoteResumePrice | 666666 | BUY STOP at this price resumes the EA. | Test on demo. |
| RemoteNewCyclePrice | 888888 | BUY STOP disables New Cycle; SELL LIMIT enables it. | OFF blocks new chains; ON permits new chains again. |
| RemoteStopSidePrice | 555555 | BUY STOP means Stop Buy; SELL LIMIT means Stop Sell. | Stop Buy switches to Sell Only; Stop Sell switches to Buy Only. Use the direction buttons on the panel to change the mode back. |
Debug
Diagnostic logging.
Processing logic: Important events are always logged. Enable Debug to see why signals or gates reject an entry.
| Input | Default | Meaning | Example / notes |
|---|---|---|---|
| DebugLogEnabled | false | Enable MatsDebug. | Enable while investigating issues. |