Bollinger Bands EA (Convert from Pine Script to MQ4L)

MQL4 Experten

Spezifikation

Hello, I'd need help to code a simple EA based on Bollinger Bands indicator. The code is below in Pine Script (from Trading View platform) and need to convert it to Metatrader

thanks


//////// 

len = input(20, minval=1, title="Length") 
multiplier = input(4, minval=1, title="multiplier") 
trendTimeFrame = input(60, minval=1, title="Trend Time Frame") 
useTrendFilter = input(true, type=bool, title = "Use Trend Filter") 

src = input(close, title="Source") 
out = sma(src, len) 
//plot(out, title="SMA", color=blue) 

stdOut = stdev(close, len) 
bbUpper = out + stdOut * multiplier 
bbLower = out - stdOut * multiplier 
bbUpper2 = out + stdOut * (multiplier / 2) 
bbLower2 = out - stdOut * (multiplier / 2) 
bbUpperX2 = out + stdOut * multiplier * 2 
bbLowerX2 = out - stdOut * multiplier * 2 
bbWidth = (bbUpper - bbLower) / out 


closeLongTerm = security(tickerid, tostring(trendTimeFrame), close) 
smaLongTerm = security(tickerid, tostring(trendTimeFrame), sma(close,20)) 

//plot(smaLongTerm, color=red) 

trendUp = useTrendFilter ? (closeLongTerm > smaLongTerm) : true 
trendDown = useTrendFilter? (closeLongTerm < smaLongTerm) : true 

bearish = ((cross(close,bbUpper2) == 1) or (cross(close,out) == 1)) and (close[1] > close) and trendDown 
bullish = ((cross(close,bbLower2) == 1) or (cross(close,out) == 1)) and (close[1] < close) and trendUp 


closeBuy = (high[1] > bbUpper[1]) and (close < bbUpper) and (close < open) and trendUp 
closeSell = (((low[1] bbLower)) or ((low[2] bbLower[1]))) and (close > open) and trendDown 


cutLossBuy = iff(bbWidth > 0.005, (low bbLower[1]) and trendUp, (low bbLowerX2[1]) and trendUp) 
cutLossSell = iff(bbWidth > 0.005, (high > bbUpper) and (high[1] bbUpperX2) and (high[1] < bbUpperX2[1]) and trendDown) 


if (bullish) 
strategy.entry("Buy", strategy.long, comment="Buy") 

if (bearish) 
strategy.entry("Sell", strategy.short, comment="Sell") 


strategy.close("Buy", closeBuy or cutLossBuy) 

strategy.close("Sell", closeSell or cutLossSell)


Bewerbungen

1
Entwickler 1
Bewertung
(13)
Projekte
24
42%
Schlichtung
3
33% / 0%
Frist nicht eingehalten
4
17%
Frei
2
Entwickler 2
Bewertung
(117)
Projekte
138
41%
Schlichtung
30
7% / 77%
Frist nicht eingehalten
17
12%
Frei
Ähnliche Aufträge
ACS Based on Mt4 EA 30 - 80 USD
Hai These ACS&Csdash indicators work in the same way but provide signals of different currency pairs. And Either of these two ACS indicators should be selected any one and set to trade. It provides signals of multiple currency pairs in the interface So the EA should work like that to trade multiple currency pairs on one chart. CsDash should analyze whether it is a strong signal to show on the dash board and make a
Hi i am looking a perfect programmer who can help me to fix my EA or recode it again - Error in new series button, when I click off => EA still trades new series -max lot function also not working properly -fix if there is more error during testing
I need strong robots but to work with great professionalism in solving hot markets because the market is very volatile, for these needs the strategy of EURUSD GBPJPY and GBPUSD should also be a signal strategy
Hi Developer, I'm having an issue with one EA that works on market structure break using limit orders and had many slippage during news impact and I had to manually close the limit orders every time which is cumbersome. I know that are some News Filter EA in the MQL market but it is not as I desire. I want a developer to help me out to develop an EA to control other EAs that has no news filter thru magic number if
Automate my trading 30 - 100 USD
Hi, I need a mql5 EA sellstop buystop for one minute time frame in all currency pair. That ea would be autotrade and close once profitable. I will pay once confirms the ea profit in each trade
Dear coder, I need an MT5 expert advisor with parameters detailed as : https://drive.google.com/drive/folders/18LBhYTb8bYz3pM2Szyyq4-RoTmBtaWIw?usp=sharing 1)Need the EA code to be optimisation friendly and hence able to be optimise with the shortest time possible especially when using Fast Genetic : Complex criterion using open price or OHLC 2)Able to provide sourcecode 3)Able to resolve ongoing bug if any . 4)Able
Hi developers, would like an EA developed that I can use for backtesting and possibly as a Trading Robot if I have enough confidence in it. Here are the rules: EA is for forex, indicies, commodities etc. 5 minute timeframe (can add more timeframes depending on development cost) Price at 9pm is "noted" Then the price at the following 7am is "noted". Once a candle closes above/below the 7am price in the direction of
QuantumTrader 30 - 200 USD
Request for development of machine learning robots for MetaTrader 5 (MT5) **Description**: Willing to develop experience in programming trading robots using MQL5 language and can learn machine learning on MetaTrader 5 (MT5) platform. The robot should be able to implement a multidisciplinary strategy on a set of technical indicators and multiple rules. I need to develop the robots so that they can work in an
The goal is to develop a system that mirrors trade actions (Buy/Sell) from a CTrader demo account on Cronos Markets to multiple prop firm accounts on TradeLocker, ensuring accurate replication of trades while adjusting risk proportionally. I was wondering if you could help me with copy trading an EA’s action on Cronos markets (uses CTrader) into a prop firm account that I bought with TooOne Trader (uses TradeLocker
I ask for my requirements as follows for a developer who knows how to connect accounts for those who are successful, that is copy trade VPS, so I ask that this order be very effective and very high standards in the work that will give fruit especially

Projektdetails

Budget
10 USD
Für die Entwickler
9 - 9 USD
Ausführungsfristen
von 1 bis 2 Tag(e)