Disliked{quote} Most probbly you need to NormalizeDouble(Price,_Digits) for every price you input into OrderSend() and OrderModify().Ignored
1
I will code your pivot EAs for no charge 24 replies
I will code your scalping EAs for no charge 163 replies
Oanda MT4 - Indicators and EAs not showing 2 replies
EAs and indicators relating to moutaki... 22 replies
InterbankFX has loaded its MT4 platform with custom EAs, indicators and scripts 1 reply
Disliked{quote} Most probbly you need to NormalizeDouble(Price,_Digits) for every price you input into OrderSend() and OrderModify().Ignored
DislikedМне стыдно просить об этом, но я нигде не могу его найти, хотя бы тот, который работает. Я ищу типичный...Ignored
DislikedI feel ashamed to ask for it but I cannot find it anywhere, at least one that works I'm looking for the typical indi for mt4 that tells you how many time remains to close the candle If someone can share thanks in advanceIgnored
Disliked...combining the MT4 Accelerator oscillator and the Awesome oscillator; when their combined histogram matches, i need an arrow to appear on chart on current/closed candle with pop up alerts...only appear on the first match...Ignored
DislikedHello, I would like to try a simple strategy (TF 5 min.) with an EA that trades as follows: Go long when * 20 SMA > 50 SMA and * Stoch (5,3) is 25 or less and * Signal candle is bullish (i.e., hammer, doji, piercing, etc.) and * The close of the signal candle is less than the high of the previous candle. SL/TP: * SL (1x ATR) – low of entry bar * Target exit: (2 x ATR) + entry price or market price at close of trading (for that it would be great if it’s possible to specify start and end time of trading), whatever comes first * ATR-rule: if SL = 2x...Ignored
Disliked...Horizontal EMA indicator...Time frame can be changed...Period...method...Apply to...Ignored
Disliked{quote} Apologies to those 40 people who downloaded the previous indicator, the code was not updating the past levels in real time when the inputs were set to "Extend lines to current price = true". I never tested the indicator for real time updating as I wrongly assumed that the original code would update but have since found and deleted 2 lines of the original code that was preventing the real time update. {file} {image} {image} {image}Ignored
// input variables int mnBUY=10; // Magic Number for BUY Trades int mnSEL=20; // Magic Number for SELL Trades datetime bOpTm=0, sOpTm=0; double bOpPx=0, sOpPx=0; for(int i=OrdersTotal()-1; i>=0; i--) { if(OrderSelect(i,SELECT_BY_POS) && OrderSymbol()==symbol) { bOpTm=OrderOpenTime(); bOpPx=OrderOpenPrice(); if(OrderMagicNumber()==mnBUY) {i=bOpTm; i=bOpPx;}} { sOpTm=OrderOpenTime(); sOpPx=OrderOpenPrice(); if(OrderMagicNumber()==mnSEL) {i=sOpTm; i=sOpPx;}} }
Disliked{quote} With all the criteria so well defined, I'm sure ChatGPT could whip that up in, oh, 5-seconds, try it and seeIgnored
Dislikedanyone have this indicator mq4 file.. can someone share.. or create new indicator similar to like this but with mq4 file {file}Ignored
Dislikedanyone have this indicator mq4 file.. can someone share.. or create new indicator similar to like this but with mq4 file {file}Ignored
//+------------------------------------------------------------------+ //| Heikin_Ashi_ZigZag.mq4 | //| Naguisa Unada | //| None | //+------------------------------------------------------------------+ #property copyright "Naguisa Unada" #property link "https://www.mql5.com/en/users/unadajapon/news" #property version "1.00" #property strict #property indicator_chart_window #property indicator_buffers 5 #property indicator_plots 5 #define _mtfCall(_buff, _y) iCustom(NULL, TimeFrame, IndicatorFileName, PERIOD_CURRENT, _buff, _y) #define _interpolate(buff) buff[i + k] = buff[i] + (buff[i + n] - buff[i]) * k / n //--- plot Hige1_ #property indicator_label1 "Hige1_" #property indicator_type1 DRAW_HISTOGRAM #property indicator_color1 clrRed #property indicator_style1 STYLE_SOLID #property indicator_width1 1 //--- plot Hige2_ #property indicator_label2 "Hige2_" #property indicator_type2 DRAW_HISTOGRAM #property indicator_color2 clrLimeGreen #property indicator_style2 STYLE_SOLID #property indicator_width2 1 //--- plot Body1_ #property indicator_label3 "Body1_" #property indicator_type3 DRAW_HISTOGRAM #property indicator_color3 clrRed #property indicator_style3 STYLE_SOLID #property indicator_width3 3 //--- plot Body2_ #property indicator_label4 "Body2_" #property indicator_type4 DRAW_HISTOGRAM #property indicator_color4 clrLimeGreen #property indicator_style4 STYLE_SOLID #property indicator_width4 3 //--- plot ZigZag #property indicator_label5 "ZigZag_" #property indicator_type5 DRAW_SECTION #property indicator_color5 clrSilver #property indicator_style5 STYLE_SOLID #property indicator_width5 1 //--- input parameters input ENUM_TIMEFRAMES TimeFrame = PERIOD_CURRENT; // Time Frame input bool Interpolate = true; // Interpolate input bool Show_ZigZag = true; // Show ZigZag input bool alert_ON = true; // Alert switch input bool alert_Current = false; // Alert on Current bar input bool alert_Message = true; // Alert Message input bool alert_Sound = true; // Alert Sound input bool alert_Email = false; // Send E-mail input bool alert_Notify = false; // Send Push nortification input string Soundfile = "alert2.wav"; // Alert sound file //--- indicator buffers double Hige1_Buffer[]; double Hige2_Buffer[]; double Body1_Buffer[]; double Body2_Buffer[]; double ZigZag_Buffer[]; string IndicatorFileName, short_name; int tFrame; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+ int OnInit() { //--- indicator buffers mapping SetIndexBuffer(0, Hige1_Buffer); SetIndexBuffer(1, Hige2_Buffer); SetIndexBuffer(2, Body1_Buffer); SetIndexBuffer(3, Body2_Buffer); if (Show_ZigZag) SetIndexBuffer(4, ZigZag_Buffer); if (TimeFrame < Period()) tFrame = Period(); else tFrame = TimeFrame; string TimeFrameStr = GetTimeFrameString(tFrame); short_name = "HeikinAshi_ZigZag-" + TimeFrameStr; IndicatorShortName(short_name); IndicatorFileName = WindowExpertName(); //--- return(INIT_SUCCEEDED); } //+------------------------------------------------------------------+ //| Custom indicator iteration function | //+------------------------------------------------------------------+ int OnCalculate(const int rates_total, const int prev_calculated, const datetime &time[], const double &open[], const double &high[], const double &low[], const double &close[], const long &tick_volume[], const long &volume[], const int &spread[]) { //--- int i, y, n, k, limit, pos; datetime ctime; double haOpen, haHigh, haLow, haClose; if (rates_total < 10) return(-1); if (prev_calculated < 0) return(-1); if (prev_calculated == 0) limit = rates_total - 5; else limit = rates_total - prev_calculated + 1; if (tFrame == Period()) { for (i = limit; i >= 0; i--) { haOpen = (Body1_Buffer[i + 1] + Body2_Buffer[i + 1]) / 2; haClose = (open[i + 3] + high[i + 3] + low[i + 3] + close[i + 3] + open[i + 2] + high[i + 2] + low[i + 2] + close[i + 2] + open[i + 1] + high[i + 1] + low[i + 1] + close[i + 1] + open[i] + high[i] + low[i] + close[i] * 3) / 18; haHigh = MathMax(high[i], MathMax(haOpen, haClose)); haLow = MathMin(low[i], MathMin(haOpen, haClose)); if (haOpen < haClose) { Hige1_Buffer[i] = haLow; Hige2_Buffer[i] = haHigh; } else { Hige1_Buffer[i] = haHigh; Hige2_Buffer[i] = haLow; } Body1_Buffer[i] = haOpen; Body2_Buffer[i] = haClose; } if (Show_ZigZag) { for (i = limit; i >= 0; i--) { ZigZag_Buffer[i + 1] = EMPTY_VALUE; if (Body1_Buffer[i] < Body2_Buffer[i] && Body1_Buffer[i + 1] > Body2_Buffer[i + 1]) ZigZag_Buffer[i + 1] = Hige2_Buffer[i + 1]; if (Body1_Buffer[i] > Body2_Buffer[i] && Body1_Buffer[i + 1] < Body2_Buffer[i + 1]) ZigZag_Buffer[i + 1] = Hige2_Buffer[i + 1]; } } } else { limit = (int)MathMax(limit, MathMin(rates_total - 5, (limit + 1) * tFrame / Period())); for (i = limit; i >= 0; i--) { y = iBarShift(NULL, tFrame, time[i]); Hige1_Buffer[i] = _mtfCall(0, y); Hige2_Buffer[i] = _mtfCall(1, y); Body1_Buffer[i] = _mtfCall(2, y); Body2_Buffer[i] = _mtfCall(3, y); if (Show_ZigZag) ZigZag_Buffer[i] = _mtfCall(4, y); if (!Interpolate || (i > 0 && y == iBarShift(NULL, tFrame, time[i - 1]))) continue; ctime = iTime(NULL, tFrame, y); for (n = 1; (i + n) < rates_total && time[i + n] >= ctime; n++) continue; for (k = 1; k < n && (i + n) < rates_total && (i + k) < rates_total; k++) { _interpolate(Hige1_Buffer); _interpolate(Hige2_Buffer); _interpolate(Body1_Buffer); _interpolate(Body2_Buffer); if (Show_ZigZag) _interpolate(ZigZag_Buffer); } } } if (alert_ON && Show_ZigZag) { if (alert_Current) pos = 0; else pos = 1; if (ZigZag_Buffer[pos + 1] != EMPTY_VALUE && Body1_Buffer[pos] < Body2_Buffer[pos]) Do_Alert(" Up Trend"); else if (ZigZag_Buffer[pos + 1] != EMPTY_VALUE && Body1_Buffer[pos] > Body2_Buffer[pos]) Do_Alert(" Down Trend"); } //--- return value of prev_calculated for next call return(rates_total); } //+------------------------------------------------------------------+ string GetTimeFrameString(int timeFrame) { string TimeFrameStr; switch(timeFrame) { case PERIOD_M1 : TimeFrameStr = "Period_M1"; break; case PERIOD_M5 : TimeFrameStr = "Period_M5"; break; case PERIOD_M15 : TimeFrameStr = "Period_M15"; break; case PERIOD_M30 : TimeFrameStr = "Period_M30"; break; case PERIOD_H1 : TimeFrameStr = "Period_H1"; break; case PERIOD_H4 : TimeFrameStr = "Period_H4"; break; case PERIOD_D1 : TimeFrameStr = "Period_D1"; break; case PERIOD_W1 : TimeFrameStr = "Period_W1"; break; case PERIOD_MN1 : TimeFrameStr = "Period_MN1"; break; default : TimeFrameStr = "Current TF"; } return(TimeFrameStr); } //+------------------------------------------------------------------+ void Do_Alert(string doWhat) { static string prev_alert = "nothing"; static datetime prev_time; string message; if (prev_alert != doWhat || prev_time != Time[0]) { prev_alert = doWhat; prev_time = Time[0]; message = StringConcatenate(Symbol(), " at ", TimeToStr(TimeLocal(), TIME_SECONDS), " ", short_name, doWhat); if (alert_Message) Alert(message); if (alert_Email) SendMail(StringConcatenate(Symbol(), " ", short_name), message); if (alert_Notify) SendNotification(message); if (alert_Sound) PlaySound(Soundfile); } } //+------------------------------------------------------------------+
DislikedHello guys. Is there any availibility to create EA from this pine script? I found this strategy on TradingView. //@version=4 //Time Frame: H1 strategy("Pin Bar Magic v1", overlay=true) // User Input usr_risk = input(title="Equity Risk (%)",type=input.integer,minval=1,maxval=100,step=1,defval=3,confirm=false) atr_mult = input(title="Stop Loss (x*ATR, Float)",type=input.float,minval=0.1,maxval=100,step=0.1,defval=0.5,confirm=false) slPoints = input(title="Stop Loss Trail Points (Pips)",type=input.integer,minval=1,maxval=1000,step=1,defval=1,confirm=false)...Ignored
DislikedHi coders, I'm a beginner, please help as I do not know the correct way to code. I would like to get below Open Trades info from a loop :- 1) OrderOpenTime() of BUY open order, i.e. bOpTm 2) OrderOpenTime() of SELL open order, i.e. sOpTm 3) OrderOpenPrice() of BUY open order, i.e. bOpPx 4) OrderOpenPrice() of SELL open order, i.e. sOpPx You may have a question what if there are 3 BUY open trades and 5 SELL open trades for a symbol, but no worry about the number of BUY and SELL trades as I have set to maximum number of BUY trades=1 and maximum number...Ignored
// input variables int mnBUY=10; // Magic Number for BUY Trades int mnSEL=20; // Magic Number for SELL Trades datetime bOpTm=0, sOpTm=0; double bOpPx=0, sOpPx=0; string symbol=_Symbol; for(int i=OrdersTotal()-1; i>=0; i--) { if(OrderSelect(i,SELECT_BY_POS) && OrderSymbol()==symbol) { if(OrderMagicNumber()==mnBUY) { bOpTm=OrderOpenTime(); bOpPx=OrderOpenPrice(); } if(OrderMagicNumber()==mnSEL) { sOpTm=OrderOpenTime(); sOpPx=OrderOpenPrice(); } } }