MQL5 Refactor Job – NIKA_FTS (REV + PSAR + HA only, closed-candle, max speed)

MQL5 Indicadores

Trabalho concluído

Tempo de execução 17 dias
Comentário do desenvolvedor
GOOD CLIENT
Comentário do cliente
good guy

Termos de Referência

Summary

Refactor my current NIKA_FTS.mq5 into a minimal, fast, backtest-deterministic indicator that keeps:

  • Tilson T3 pair (fast/slow) with separate alphas → drives REV state

  • PSAR (plot + up/down cross signals)

  • Heikin-Ashi overlay (candles/bars/hollow), colored by REV state

Remove everything else (RSI, TSI, TRM, MA1/2/3, MA crosses, Curl, bar-color logic from RSI/TRM, etc.).
All logic must be closed-candle only (no live/intrabar behavior).


Scope of Work

KEEP & Implement

  1. Tilson T3 (double-alpha)

    • Inputs:

      input int aLength = 5; // fast T3 length input int Length = 8; // slow T3 length input double alphaFast = 0.70; // fast T3 alpha input double alphaSlow = 0.70; // slow T3 alpha

    • Buffers: anT3Average[] (fast), nT3Average[] (slow)

    • Plots: T3 Fast color line, T3 Slow color line, T3 Fill between them

    • Calls:

              calc_t3_series(src_arr, total, aLength, alphaFast, anT3Average);
      calc_t3_series(src_arr, total, Length , alphaSlow, nT3Average);
      
  2. REV state (Tilson-based)

    • For bar i (closed bars only):

      • uc : anT3Average[i] >= nT3Average[i] && Close[i] > nT3Average[i]

      • dc : anT3Average[i] <= nT3Average[i] && Close[i] < nT3Average[i]

      • ur : anT3Average[i] <= nT3Average[i] && Close[i] > nT3Average[i] (cross up)

      • dr : anT3Average[i] >= nT3Average[i] && Close[i] < nT3Average[i] (cross down)

    • Output buffer: Rev[] = +1 (bull: uc/ur), -1 (bear: dc/dr), 0 otherwise.

  3. PSAR

    • Inputs: start , inc_v , max_v

    • Use iSAR() handle; copy to sar[]

    • Signal buffer: SARsig[] = +1 if Close[i] >= sar[i] , else -1

    • Plot: dots/arrows (bull/bear color by state)

  4. Heikin-Ashi overlay (KEEP)

    • Inputs:

      enum CandleType {CT_Candles }; input CandleType type =

              CT_Candles 
      input bool haover = true; input bool rPrice = false; // optional real-close line

    • Buffers: hac_* and/or hab_* + color index buffer

    • Color rule: map REV → HA color

      • Rev>0 → bull; Rev<0 → bear; Rev==0 → neutral

  5. Alerts (closed-bar only)

    • Mode input:

      enum AlertMode { AM_PER_BAR=0, AM_PER_BAR_CLOSE }; input AlertMode i_alert_mode = AM_PER_BAR_CLOSE; input bool REVUP=false, REVDWN=false, SARUP=false, SARDWN=false;

    • Trigger only on last fully closed bar:

      • REVUP : Close[i-1] <= nT3[i-1] && Close[i] > nT3[i]

      • REVDWN : Close[i-1] >= nT3[i-1] && Close[i] < nT3[i]

      • SARUP : cross above PSAR

      • SARDWN : cross below PSAR

  6. 2-row table (Rev, SAR)

    • Inputs:

              input bool showTable=false;
      input int  textSize=12, textWidth=100, textHeight=25, tableYpos=10, tableXpos=10;
      
    • Rows: “Rev”, “SAR”; icons ✅ / ❌ / 🔸 .

    • Update only when a new bar closes (no per-tick redraw).

REMOVE / PRUNE

  • All RSI/TSI/TRM/MA/Curl code: enums, inputs, buffers, plots, alerts, palette colors, paint logic, table cells.

  • Any leftover live/intrabar logic (e.g., using TimeCurrent , per-tick alerts, on-the-fly objects).

  • Any plotting/objects unrelated to T3/PSAR/HA/table.


Closed-Candle-Only Rules (hard requirement)

  • In OnCalculate , set:

    const int last_closed = rates_total - 2; int start = (prev_calculated>0 ? prev_calculated-1 : warmup); for(int i=start; i<=last_closed; ++i) { ... } // NEVER use rates_total-1 in logic

  • Use data from arrays time[]/open[]/high[]/low[]/close[] only.

  • No SymbolInfoDouble(BID/ASK) or TimeCurrent() in logic/alerts.

  • Alerts and table update only when time[last_closed] changes (track static datetime last_bar_time ).


Performance & Code Quality (hard requirement)

  • Max speed / zero “dirty” code:

    • Single pass loop, no nested loops per bar.

    • Respect prev_calculated . Start at max(prev_calculated-1, warmup) .

    • Pre-allocate & reuse buffers; ArraySetAsSeries(..., true) once.

    • No dynamic ObjectCreate/Delete inside the bar loop. Table draw only once per closed bar; otherwise disabled.

    • Move branches out of hot loops; precompute booleans reused multiple times.

    • Keep #property indicator_plots and indicator_buffers to exact counts used.

    • Avoid repeated switch / Math* in hot path when possible; cache inputs.

    • Use built-in iSAR handle; a single CopyBuffer per call; fill EMPTY_VALUE for overflow.

    • No sleeps, prints, file I/O, or terminal calls in calc loop.

  • Backtest determinism:

    • No tick-dependent state. Results must be identical in visual/non-visual and multi-core tester.

    • No dependence on chart scaling/zoom or user objects.

  • Deinit hygiene: ObjectsDeleteByPrefix(0,"NIKA-") ; do not nuke user objects.


Final Inputs (only)

// T3
input int    aLength   = 5;
input int    Length    = 8;
input double alphaFast = 0.70;
input double alphaSlow = 0.70;

// PSAR
input double start = 0.043;
input double inc_v = 0.043;
input double max_v = 0.34;

// Visuals
enum CandleType { CT_Hollow=0, CT_Bars, CT_Candles };
input CandleType type = CT_Hollow;
input bool t3vis   = true;
input bool psarvis = true;
input bool haover  = true;
input bool rPrice  = false;

// Alerts (closed-bar only)
enum AlertMode { AM_PER_BAR=0, AM_PER_BAR_CLOSE };
input AlertMode i_alert_mode = AM_PER_BAR_CLOSE;
input bool REVUP=false, REVDWN=false, SARUP=false, SARDWN=false;

// Optional table
input bool showTable=false;
input int  textSize=12, textWidth=100, textHeight=25, tableYpos=10, tableXpos=10;

Required Buffers/Plots

  • Calc: anT3Average[] , nT3Average[] , sar[] , src_arr[] , HA arrays ( hac_* / hab_* )

  • Signals: Rev[] , SARsig[]

  • Plots:

    • Color-line T3 Fast , color-line T3 Slow , T3 Fill (2 buffers)

    • PSAR dots

    • HA candles/bars/hollow (color index)

    • Real Close line (optional)

  • Palette: only colors used by T3/PSAR/HA.


Acceptance Tests

  1. Compilation: MT5 current build, 0 errors / 0 warnings.

  2. Search-clean: No occurrences of RSI , TSI , TRM , MA1 , MA2 , MA3 , HCROSS , Curl .

  3. Closed-bar only: Changing tester from “Every tick” → “1 minute OHLC” yields identical buffers.

  4. Performance: On M1 with 50k bars, first load < 50ms and incremental updates scale O(1) per bar (no visible lag).

  5. Alerts: Fire once per qualifying closed bar (when AM_PER_BAR_CLOSE ), never on forming bar.

  6. HA coloring: Follows Rev state correctly; table (if enabled) shows only “Rev”, “SAR”.

  7. Determinism: Visual vs non-visual backtests produce the same Rev[]/SARsig[]/sar[]/T3 values.


Deliverables

  1. Refactored NIKA_FTS.mq5 .

  2. Short changelog of removed modules + final public API (inputs/plots/buffers).

  3. QA note with 3 screenshots:

    • Bull REV + SARUP

    • Bear REV + SARDWN

    • Neutral REV



  • Export a consolidated Signal[] buffer: +1 bull / 0 neutral / −1 bear (mirrors Rev ).

  • Inputs for line widths and PSAR dot size.


    input int    WarmupBars   = 500;     // bars to prefill T3 before signaling
    input int    MaxHistory   = 10000;  // cap processing for speed; 0 = unlimited
    input bool   UseSeries    = true;    // ArraySetAsSeries on calc buffers




Respondido

1
Desenvolvedor 1
Classificação
(25)
Projetos
31
13%
Arbitragem
14
0% / 79%
Expirado
9
29%
Livre
2
Desenvolvedor 2
Classificação
(2)
Projetos
3
0%
Arbitragem
4
0% / 50%
Expirado
0
Trabalhando
3
Desenvolvedor 3
Classificação
Projetos
0
0%
Arbitragem
0
Expirado
0
Livre
4
Desenvolvedor 4
Classificação
(185)
Projetos
199
47%
Arbitragem
4
50% / 25%
Expirado
1
1%
Trabalhando
5
Desenvolvedor 5
Classificação
(1)
Projetos
1
0%
Arbitragem
0
Expirado
0
Livre
Pedidos semelhantes
I am looking for an experienced MQL5 developer or development team to build a scalable Telegram-to-MT5 copy trading system. The main purpose of the system is to monitor trading signals from my Telegram channel and automatically execute those signals on connected client MT5 accounts. Core Requirements Receive and parse trading signals from Telegram Automatically execute trades on connected MT5 accounts Support more
Thana ram 30 - 200 USD
Hello, I want to develop a custom MT5 Expert Advisor (EA) for XAUUSD Gold. IMPORTANT: I want a proper rule-based automated trading EA, NOT a martingale, grid or guaranteed-profit bot. 1. MARKET & TIMEFRAME - Platform: MT5 - Symbol: XAUUSD only - Main trend timeframe: M15 - Entry timeframe: M5 - Must support broker suffixes such as XAUUSDm, XAUUSD., etc. 2. TREND RULE BUY trend: - M15 price above EMA 50 - EMA 50 above
I need a TradingView Pine Script (v6) indicator that gives BUY and SELL signals in real time on the live chart. MAIN REQUIREMENT – NO REPAINTING: 1. Signals must appear only when the candle closes (barstate.isconfirmed). Example: on 1-min chart, signal for the 10:35 candle must appear at 10:36 and never disappear or move. 2. Signals on historical bars must look exactly the same as they looked live. 3. No lookahead
Description I am looking for a highly skilled MQL5 Developer & Trader with strong experience in EA optimization, stress testing, and forward validation. The EA is already coded and running. What I need now is: 1.Simple code editing, code adjustment/upgrading and code tamplates inserting, 2.Parameter Optimization & Re-Validation – Find the best stable settings for XAUUSD (not overfitted). 3.Robustness / Stress Testing
المطلوب موشر لتداول الذهب مجرب وقوية يعطي اشاره قوية فقط مع وقف خساره ومختبر ومجرب في حال الموافقه علي لموشر بعد التجربه لمدة ٣ ايام يتم الشراء دايم مبلغ ٢٠٠ دولار
Strategy 40 - 60 USD
yo i have a strategy i would really like to turn into a signal bot basically please this is very technical and serious to me the strategy needs more time 1 time frame and the bot most be 100% accurate
can you help me use a Tickblaze Algo NRBO on the NT platform? I have it somewhat set up, but I have other questions about running it & knowing how to operate it in NT. Thank you if anyone have experience in this kindly bib and let do it asap
I need a trading system similar to the attached files. Check attachment for details on the indicator. i guess the indicator contains some of (Rainbow MA , MTF Dashboard , Symbol Switcher , and Trend Histogram), though may not be exactly as listed
I have a EA/Bot I’ve designed and want it to be put onto me MetaTrader5 this month. I’m new here and also need to figure out how to get a live account and add a UK broker
‎A trending candle followed by a smaller trending candle which is the second candle with no 5EMA ‎ ‎The 3rd candle is a reversal candle in which it and it's immidiate previous candle must be at least 70% of each other's body or equal body, with no 5EMA touch ‎ ‎the 3rd candle candle is followed immediately by the 4th candle which is the signal candle in which it and the 1st cabdle must be also at least 70% of

Informações sobre o projeto

Orçamento
30 - 35 USD
Prazo
para 1 dias