Convert Tradingview's (Pinescript) Engulfing Indicators to MQL5 for MetaTrader5 Use

Lavoro terminato

Tempo di esecuzione 1 giorno
Feedback del cliente
Excellent work! Perfectly done and quick.
Feedback del dipendente
Kind and correct customer. great!!!

Specifiche

For bearish:

//@version=4

study("Engulfing - Bearish", shorttitle = "Engulfing - Bear", overlay=true)


C_DownTrend = true

C_UpTrend = true

var trendRule1 = "SMA50"

var trendRule2 = "SMA50, SMA200"

var trendRule = input(trendRule1, "Detect Trend Based On", options=[trendRule1, trendRule2, "No detection"])


if trendRule == trendRule1

priceAvg = sma(close, 50)

C_DownTrend := close < priceAvg

C_UpTrend := close > priceAvg


if trendRule == trendRule2

sma200 = sma(close, 200)

sma50 = sma(close, 50)

C_DownTrend := close < sma50 and sma50 < sma200

C_UpTrend := close > sma50 and sma50 > sma200

C_Len = 14 // ema depth for bodyAvg

C_ShadowPercent = 5.0 // size of shadows

C_ShadowEqualsPercent = 100.0

C_DojiBodyPercent = 5.0

C_Factor = 2.0 // shows the number of times the shadow dominates the candlestick body


C_BodyHi = max(close, open)

C_BodyLo = min(close, open)

C_Body = C_BodyHi - C_BodyLo

C_BodyAvg = ema(C_Body, C_Len)

C_SmallBody = C_Body < C_BodyAvg

C_LongBody = C_Body > C_BodyAvg

C_UpShadow = high - C_BodyHi

C_DnShadow = C_BodyLo - low

C_HasUpShadow = C_UpShadow > C_ShadowPercent / 100 * C_Body

C_HasDnShadow = C_DnShadow > C_ShadowPercent / 100 * C_Body

C_WhiteBody = open < close

C_BlackBody = open > close

C_Range = high-low

C_IsInsideBar = C_BodyHi[1] > C_BodyHi and C_BodyLo[1] < C_BodyLo

C_BodyMiddle = C_Body / 2 + C_BodyLo

C_ShadowEquals = C_UpShadow == C_DnShadow or (abs(C_UpShadow - C_DnShadow) / C_DnShadow * 100) < C_ShadowEqualsPercent and (abs(C_DnShadow - C_UpShadow) / C_UpShadow * 100) < C_ShadowEqualsPercent

C_IsDojiBody = C_Range > 0 and C_Body <= C_Range * C_DojiBodyPercent / 100

C_Doji = C_IsDojiBody and C_ShadowEquals


patternLabelPosLow = low - (atr(30) * 0.6)

patternLabelPosHigh = high + (atr(30) * 0.6)


C_EngulfingBearishNumberOfCandles = 2

C_EngulfingBearish = C_UpTrend and C_BlackBody and C_LongBody and C_WhiteBody[1] and C_SmallBody[1] and close <= open[1] and open >= close[1] and ( close < open[1] or open > close[1] )

alertcondition(C_EngulfingBearish, title = "Engulfing", message = "New Engulfing - Bearish pattern detected.")

if C_EngulfingBearish

    var ttBearishEngulfing = "Engulfing\nAt the end of a given uptrend, a reversal pattern will most likely appear. During the first day, this candlestick pattern uses a small body. It is then followed by a day where the candle body fully overtakes the body from the day before it and closes in the trend’s opposite direction. Although similar to the outside reversal chart pattern, it is not essential for this pattern to fully overtake the range (high to low), rather only the open and the close."

    label.new(bar_index, patternLabelPosHigh, text="BE", style=label.style_label_down, color = color.red, textcolor=color.white, tooltip = ttBearishEngulfing)

bgcolor(highest(C_EngulfingBearish?1:0, C_EngulfingBearishNumberOfCandles)!=0 ? color.red : na, offset=-(C_EngulfingBearishNumberOfCandles-1))



For bullish:

//@version=4

study("Engulfing - Bullish", shorttitle = "Engulfing - Bull", overlay=true)


C_DownTrend = true

C_UpTrend = true

var trendRule1 = "SMA50"

var trendRule2 = "SMA50, SMA200"

var trendRule = input(trendRule1, "Detect Trend Based On", options=[trendRule1, trendRule2, "No detection"])


if trendRule == trendRule1

priceAvg = sma(close, 50)

C_DownTrend := close < priceAvg

C_UpTrend := close > priceAvg


if trendRule == trendRule2

sma200 = sma(close, 200)

sma50 = sma(close, 50)

C_DownTrend := close < sma50 and sma50 < sma200

C_UpTrend := close > sma50 and sma50 > sma200

C_Len = 14 // ema depth for bodyAvg

C_ShadowPercent = 5.0 // size of shadows

C_ShadowEqualsPercent = 100.0

C_DojiBodyPercent = 5.0

C_Factor = 2.0 // shows the number of times the shadow dominates the candlestick body


C_BodyHi = max(close, open)

C_BodyLo = min(close, open)

C_Body = C_BodyHi - C_BodyLo

C_BodyAvg = ema(C_Body, C_Len)

C_SmallBody = C_Body < C_BodyAvg

C_LongBody = C_Body > C_BodyAvg

C_UpShadow = high - C_BodyHi

C_DnShadow = C_BodyLo - low

C_HasUpShadow = C_UpShadow > C_ShadowPercent / 100 * C_Body

C_HasDnShadow = C_DnShadow > C_ShadowPercent / 100 * C_Body

C_WhiteBody = open < close

C_BlackBody = open > close

C_Range = high-low

C_IsInsideBar = C_BodyHi[1] > C_BodyHi and C_BodyLo[1] < C_BodyLo

C_BodyMiddle = C_Body / 2 + C_BodyLo

C_ShadowEquals = C_UpShadow == C_DnShadow or (abs(C_UpShadow - C_DnShadow) / C_DnShadow * 100) < C_ShadowEqualsPercent and (abs(C_DnShadow - C_UpShadow) / C_UpShadow * 100) < C_ShadowEqualsPercent

C_IsDojiBody = C_Range > 0 and C_Body <= C_Range * C_DojiBodyPercent / 100

C_Doji = C_IsDojiBody and C_ShadowEquals


patternLabelPosLow = low - (atr(30) * 0.6)

patternLabelPosHigh = high + (atr(30) * 0.6)


C_EngulfingBullishNumberOfCandles = 2

C_EngulfingBullish = C_DownTrend and C_WhiteBody and C_LongBody and C_BlackBody[1] and C_SmallBody[1] and close >= open[1] and open <= close[1] and ( close > open[1] or open < close[1] )

alertcondition(C_EngulfingBullish, title = "Engulfing", message = "New Engulfing - Bullish pattern detected.")

if C_EngulfingBullish

    var ttBullishEngulfing = "Engulfing\nAt the end of a given downward trend, there will most likely be a reversal pattern. To distinguish the first day, this candlestick pattern uses a small body, followed by a day where the candle body fully overtakes the body from the day before, and closes in the trend’s opposite direction. Although similar to the outside reversal chart pattern, it is not essential for this pattern to completely overtake the range (high to low), rather only the open and the close."

    label.new(bar_index, patternLabelPosLow, text="BE", style=label.style_label_up, color = color.blue, textcolor=color.white, tooltip = ttBullishEngulfing)

bgcolor(highest(C_EngulfingBullish?1:0, C_EngulfingBullishNumberOfCandles)!=0 ? color.blue : na, offset=-(C_EngulfingBullishNumberOfCandles-1))


*The bullish and bearish indicators shall be combined into one indicator, any object e.g. arrow can be used to indicate the signal, plus integration of alerts. Trend rules not necessary and may be removed for simplicity. Conditions in bold text are the only ones necessary to create arrow object and alert. Thank you.


Con risposta

1
Sviluppatore 1
Valutazioni
(166)
Progetti
189
10%
Arbitraggio
37
38% / 35%
In ritardo
5
3%
Caricato
2
Sviluppatore 2
Valutazioni
(126)
Progetti
159
35%
Arbitraggio
4
25% / 50%
In ritardo
13
8%
In elaborazione
3
Sviluppatore 3
Valutazioni
(402)
Progetti
530
74%
Arbitraggio
9
44% / 0%
In ritardo
24
5%
Gratuito
Ordini simili
I want the trade to trigger anytime it sees the opportunity on all time frames, sl tp should be automated and all trades should be trigger anytime on cpi news and etc
I need someone to help me convert my tradingview pinescript to mt4, I only got $20 for this and I am gonna be giving you more works ahead, Also I will be paying with cryptocurrency cause my PayPal os not working here, Don't know why
I need someone to help me convert my tradingview pinescript to mt4, my budget for this project is $20 and I need this done fast in two days, Also, I am going to need you to be able to build a new indicator because that's the nest project, But I need to know if you can do this first , Thank you
I need you to convert my tradingview pinescript to mt4, I have just $10 for it now, But i am going to give you more work later on cause i still have more work i am going to need you to work on for me, and i will be paying with crypto, Thank You
Hello, I am in need of an expert to help me convert my tradingview pinescript to mt4, I will attach the file, But for now, I only got $15 for this project and the only payment method I can use right now is crypto, I will send it to you through crypto, Also I need someone that is ready to work because I still have lot of projects I will need him to do for me
Hello, I need a quote for developing a bot for my renko based trading system on ctrader platform and based on the attached specification your expertise is highly needed for this project Thanks
Hello to all developers, I need someone that can help me with my ea project. I want to do ea Only reverse engineering (writing from scratch by analyzing the algorithm), without decompilation Here are the files https://drive.google.com/folderview?id=1A9uJNbvFM1pvYHRLTIDf5ThgeJu88eJp
Hello, please let me know if any of these strategies can be turned into a bot (automation) and run 24/7 on a vps. Also note that they might not use the latest versions of indicators, if this matters, then please check for the latest versions. Thank you! Dan https://1drv.ms/f/s!Alr17W7ddJLYgYgiFKZYluOfokbfQg
Hello! Thanks for reading. I need an EA with an inbuilt/already made strategy that I can use for prop firms. The drawdown should be very low of only 2-4% max and another criteria is that no one else other than you are currently using it and if you happen to use it you must tell me which prop firm you are using it on to avoid us using the same EA on the same prop firm to get the account denied. As you know or may
Hello please I need a developer to help me fix errors on my Ninjatrader 8 strategy I and make it work perfectly your expertise is need for this project kindly reach out to me and let's proceed

Informazioni sul progetto

Budget
30 - 40 USD
Per lo sviluppatore
27 - 36 USD
Scadenze
da 2 a 4 giorno(i)