Convert TradingView Pine Script to Metatrader 5 Expert Advisor

Tâche terminée

Temps d'exécution 2 jours
Commentaires du client
Fast and honest.

Spécifications

Hi,

I need to convert the Super Trend 2 Strategy from Tradingview Pine Script to Meta Trader5 EA, so that it can open and close orders on its own.

Supertrend is a strategy by breizh29 using *rajandran.r* Supertrend Indicator, and here is the original code:



strategy("Super Trend 2", overlay=true, default_qty_value=100)

res = input(title="Main SuperTrend Time Frame", type=resolution, defval="120")

Factor=input(1, minval=1,maxval = 100)

Pd=input(1, minval=1,maxval = 100)


tp = input(500,title="Take Profit")

sl = input(400,title="Stop Loss")



Up=hl2-(Factor*atr(Pd))

Dn=hl2+(Factor*atr(Pd))

MUp=security(tickerid,res,hl2-(Factor*atr(Pd)))

MDn=security(tickerid,res,hl2+(Factor*atr(Pd)))


Mclose=security(tickerid,res,close)


TrendUp=close[1]>TrendUp[1]? max(Up,TrendUp[1]) : Up

TrendDown=close[1]<TrendDown[1]? min(Dn,TrendDown[1]) : Dn


MTrendUp=Mclose[1]>MTrendUp[1]? max(MUp,MTrendUp[1]) : MUp

MTrendDown=Mclose[1]<MTrendDown[1]? min(MDn,MTrendDown[1]) : MDn


Trend = close > TrendDown[1] ? 1: close< TrendUp[1]? -1: nz(Trend[1],1)

Tsl = Trend==1? TrendUp: TrendDown


MTrend = Mclose > MTrendDown[1] ? 1: Mclose< MTrendUp[1]? -1: nz(MTrend[1],1)

MTsl = MTrend==1? MTrendUp: MTrendDown


linecolor = Trend == 1 ? green : red

plot(Tsl, color = linecolor , style = line , linewidth = 2,title = "SuperTrend")


Mlinecolor = MTrend == 1 ? blue : orange

plot(MTsl, color = Mlinecolor , style = line , linewidth = 2,title = "Main SuperTrend")


plotshape(cross(close,Tsl) and close>Tsl , "Up Arrow", shape.triangleup,location.belowbar,green,0,0)

plotshape(cross(Tsl,close) and close<Tsl , "Down Arrow", shape.triangledown , location.abovebar, red,0,0)


up = Trend == 1 and Trend[1] == -1 and MTrend == 1 

down = Trend == -1 and Trend[1] == 1 and MTrend == -1 

plotarrow(up ? Trend : na, title="Up Entry Arrow", colorup=lime, maxheight=60, minheight=50, transp=0)

plotarrow(down ? Trend : na, title="Down Entry Arrow", colordown=red, maxheight=60, minheight=50, transp=0)



golong = Trend == 1 and Trend[1] == -1 and MTrend == 1 

goshort = Trend == -1 and Trend[1] == 1 and MTrend == -1 


strategy.entry("Buy", strategy.long,when=golong)

strategy.exit("Close Buy","Buy",profit=tp,loss=sl)

   

   

strategy.entry("Sell", strategy.short,when=goshort)

strategy.exit("Close Sell","Sell",profit=tp,loss=sl)


 



Répondu

1
Développeur 1
Évaluation
(229)
Projets
339
49%
Arbitrage
21
5% / 33%
En retard
24
7%
Gratuit
2
Développeur 2
Évaluation
(414)
Projets
670
33%
Arbitrage
60
17% / 32%
En retard
113
17%
Travail
3
Développeur 3
Évaluation
(1235)
Projets
2820
80%
Arbitrage
156
22% / 43%
En retard
487
17%
Gratuit
4
Développeur 4
Évaluation
(195)
Projets
395
28%
Arbitrage
155
20% / 52%
En retard
112
28%
Gratuit
5
Développeur 5
Évaluation
(144)
Projets
285
42%
Arbitrage
19
63% / 5%
En retard
29
10%
Gratuit
Publié : 2 codes
Commandes similaires
Need to create an MT5 EA based on break out strategy. This will be all in one EA including daily breakout, hourly breakout, support and resistance breakout, pivot breakout, super trend break out, moving average breakout. Extra features include TP, SL, breakeven, notifications, dashboard
Looking for an MT5 developer to build an automated trading bot that executes trades based on indicator signals. The bot should support flexible inputs, work across Forex, commodities, and crypto, and allow basic configuration options. If you're experienced with MT5 EAs and indicator integration, please reach out
🔹 Project Description I need a very simple MT4 (MQL4) Expert Advisor to be used on a DEMO account . Main Purpose: When enabled, the EA must prevent opening any NEW trades , while allowing existing open trades to be managed and closed normally . Required Behavior: Do NOT close any open trades. Do NOT modify TP or SL. Prevent opening of: New initial trades New trade cycles Existing trades must continue until they
Salom, Menda allaqachon ishlaydigan MQL5 ekspert maslahatchisi bor . EA to'liq ishlaydi , savdolarni to'g'ri ochadi va boshqaradi hamda qat'iy qoidalarga asoslangan mantiqqa amal qiladi . Men noldan yangi EA yaratmoqchi emasman . 🔹 Allaqachon bajarilgan ishlar: EA MQL5 da yozilgan Strategiya mantig'i to'liq va barqaror Kundalik zona mantig'i to'g'ri ishlaydi Keyingi M5 shamida yozuv bajariladi O'zgartirish (teskari)
I want a reliable and broker-independent copy-trading solution that copies trades from a master MT5 account to multiple MT4 and/or MT5 client accounts. The system is designed for stable live trading and works with any broker, handling common differences in symbols, pricing, and execution. The copier supports full trade synchronization, including trade opening, closing, partial closes, and SL/TP modifications, with
PAIR : EURUSD ONLY TIMEFRAME: M1 SESSION:LONDON SESSION ONLY(CONFIGURABLE START / END TIME) TREND FILTER: - USE VWAP AS MAIN TREND FILTER - BUY ONLY WHEN PRICE IS ABOVE VWAP - SELL ONLY WHEN PRICEIS IS BELLOW VWAP STRUCTURE CONDITION : - TRADE ONLY AFTER A VALID BOS (BREAK OF STRUCTURE) - BOS MUST BE IN THE SAME DIRECTION AS VWAP TREND -IGNORE COUNTER-TREND BOS ENTERY CONDITION (ORDER BLOCK ): - AFTER BOS , WAIT FOR
I am looking for an experienced developer to create an automated trading bot on the Quantower platform based on my trading rules. The bot should execute trades automatically. Kindly bid for it if it is what you can code for me
MT5 Expert Advisor – XAUUSD Opening Range Breakout I am looking for an experienced MQL5 developer to build a robust MT5 Expert Advisor. STRATEGY DETAILS • Instrument: XAUUSD • Timeframe: M30 • Broker: Pepperstone (Spread Betting) • Trading days: Monday–Friday only OPENING RANGE • Opening range candle: 07:00 – 07:30 UK time • EA must automatically convert UK time to broker server time • Record OR High and OR Low from
EA should trade Gann indicator arrows filtered by Autotrendline indicator. Two orders per trade and when first level of Gann indicator is reached SL of second order should be moved to breakeven
Hello, I have a strategy written in Pine Script (TradingView) that used to send signals to MetaTrader 5 via PineConnector. Now I want a native MT5 Expert Advisor (EA) written in MQL5, so I can do full backtesting and trading inside MetaTrader without any external bridge. I will provide: - Full Pine Script code - Entry and exit rules (based on BOS and OB logic) - SL/TP and dynamic risk management (R:R) - Breakeven

Informations sur le projet

Budget
30 - 50 USD
Délais
à 7 jour(s)