şundan çatallanmış MasoodIqbal/RSI-Stoch-MA-EA
Bazı kontroller başarısız oldu
Build and Deploy MT5 EA / build (push) Failing after 26s
Build and Deploy MT5 EA / deploy (push) Has been skipped
132 satır
4,2 KiB
MQL5
132 satır
4,2 KiB
MQL5
//+------------------------------------------------------------------+
|
|
//| GlobalVariables.mqh|
|
|
//| Global Variables for QuarterTheory |
|
|
//+------------------------------------------------------------------+
|
|
#property copyright "QuarterTheory x VIZION"
|
|
#property strict
|
|
|
|
#include "Config.mqh"
|
|
|
|
//================ INDICATOR HANDLES ==================//
|
|
int Stoch_Handle, ATR_Handle, ADX_Handle;
|
|
int MA_Handles[10];
|
|
|
|
//================ INDICATOR VALUES ==================//
|
|
double Stoch_K_Current = 0, Stoch_K_Previous = 0, Stoch_K_Prev2 = 0;
|
|
double Stoch_D_Current = 0;
|
|
double Current_ATR = 0;
|
|
double Current_ADX = 0;
|
|
|
|
//================ MA VALUES ==================//
|
|
double MA_Current[10];
|
|
double MA_Previous[10];
|
|
double MA_Prev2[10];
|
|
|
|
//================ FIBONACCI LEVELS ==================//
|
|
double PriceLevels[7];
|
|
|
|
//================ MOVING FIBONACCI ==================//
|
|
double MFIB_High, MFIB_Low;
|
|
double MFIB_Level_236, MFIB_Level_382, MFIB_Level_050;
|
|
double MFIB_Level_618, MFIB_Level_786;
|
|
TREND_BIAS MFIB_Bias = BIAS_NEUTRAL;
|
|
|
|
//================ STOCHASTIC KEY LEVELS ==================//
|
|
double Stoch_Levels[7] = {20.0, 35.0, 50.0, 65.0, 80.0};
|
|
|
|
//================ MARKET STATE ==================//
|
|
MODE_FAMILY Current_Family = FAMILY_TRANSITIONAL;
|
|
TREND_BIAS Current_Bias = BIAS_NEUTRAL;
|
|
TREND_STRENGTH Current_Strength = STRENGTH_WEAK;
|
|
PRICE_STATE Current_State = STATE_UNKNOWN;
|
|
|
|
MODE_FAMILY Prev_Family = FAMILY_TRANSITIONAL;
|
|
TREND_BIAS Prev_Bias = BIAS_NEUTRAL;
|
|
TREND_STRENGTH Prev_Strength = STRENGTH_WEAK;
|
|
|
|
int Mode_Confirmation_Count = 0;
|
|
int Reversal_Confirm_Counter = 0;
|
|
|
|
//================ WARNING FLAGS ==================//
|
|
bool MA7_Cross_14_Warning = false;
|
|
bool MA7_Cross_21_Warning = false;
|
|
bool MA50_Break_Warning = false;
|
|
|
|
bool Fib_Reject_Warning = false;
|
|
bool MFIB_Reject_Warning = false;
|
|
bool Fib_Reclaim_Warning = false;
|
|
bool MFIB_Reclaim_Warning = false;
|
|
bool Fib_Break_Warning = false;
|
|
bool MFIB_Break_Warning = false;
|
|
|
|
bool MA_Reject_Warning = false;
|
|
bool MA_Reclaim_Warning = false;
|
|
bool MA_Break_Warning = false;
|
|
|
|
bool Stoch_Extreme_Warning = false;
|
|
bool Stoch_Reject_Warning = false;
|
|
bool Stoch_Level_Cross = false;
|
|
|
|
bool MA50_Warning = false;
|
|
bool MA140_Warning = false;
|
|
bool MA230_Warning = false;
|
|
bool MA500_Warning = false;
|
|
|
|
bool Pullback_Warning = false;
|
|
bool Retracement_Warning = false;
|
|
bool Band_Snap_Warning = false;
|
|
|
|
bool Is_Pullback_State = false;
|
|
bool Is_Retracement_State = false;
|
|
|
|
//================ RE-ENTRY FLAGS ==================//
|
|
bool MA14_Magnet_Active = false;
|
|
bool Fib_Break_Confirmed = false;
|
|
bool MFIB_Break_Confirmed = false;
|
|
bool Strong_MA_Bounce = false;
|
|
bool Trend_Resumption = false;
|
|
|
|
//================ PRAISE SYSTEM FLAGS ==================//
|
|
bool Praise_Triple_Magnet = false;
|
|
bool Praise_Power_Couple = false;
|
|
bool Praise_MFIB_Staircase = false;
|
|
bool Praise_MFIB_Express = false;
|
|
bool Praise_MFIB_Breakout = false;
|
|
bool Praise_MA_Stack = false;
|
|
bool Praise_Clean_Reclaim = false;
|
|
bool Praise_Multi_Breakout = false;
|
|
int Praise_Count = 0;
|
|
|
|
//================ WARNING CONFLUENCE ==================//
|
|
int Warning_Confluence_Count = 0;
|
|
bool Warning_Confluence_3Plus = false;
|
|
|
|
//================ POSITION TRACKING ==================//
|
|
PositionRec OpenPositions[];
|
|
ClosedPositionRec RecentClosures[10];
|
|
int ClosureIndex = 0;
|
|
|
|
//================ STATISTICS ==================//
|
|
int TodayTrades = 0;
|
|
int BuyTrades = 0;
|
|
int SellTrades = 0;
|
|
int ClosedByReversal = 0;
|
|
|
|
int SetupCount[19];
|
|
datetime LastEntryTime[19];
|
|
|
|
//================ NEURAL NET STATE ==================//
|
|
bool NN_Initialized = false;
|
|
int NN_Bias = 0; // -1 SELL, 0 NEUTRAL, +1 BUY
|
|
double NN_Confidence = 0.0; // 0..100
|
|
double NN_RiskScore = 50.0; // 0..100
|
|
string NN_Explain = "";
|
|
datetime NN_LastRun = 0;
|
|
bool NN_UsedLastTick = false;
|
|
|
|
//================ OPENAI STATE ==================//
|
|
bool AI_Initialized = false;
|
|
datetime Last_AI_Briefing_Time = 0;
|
|
string Last_AI_Analysis = "";
|
|
int AI_Validation_Accepts = 0;
|
|
int AI_Validation_Rejects = 0;
|