Convert a tradingview indicator to MQL5

MQL5 Indikatoren

Spezifikation

p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px 'Helvetica Neue'} p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px 'Helvetica Neue'; min-height: 14.0px}

Hello

I have a simple Tradingview indicator and the source code is available.
So what I need now is you to convert the tradingview  indicator to MT5  flawlessly.

Like always source code will be delivered at the end

This is the link to the source code .
The indicator have 10 differents moving average ['SMA', 'EMA', 'WMA', 'DEMA', 'TMA', 'VAR', 'WWMA', 'ZLEMA', 'TSF', 'HULL'], I only need the MT5 default MA

//@version=5
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/
// © KivancOzbilgic

//created by: @Anil_Ozeksi
//developer: ANIL ÖZEKŞİ
//author: @kivancozbilgic

indicator('HIGH AND LOW Optimized Trend Tracker', 'HL OTT', overlay=true)
length = input.int(2, 'OTT Period', minval=1)
percent = input.float(0.6, 'OTT Optimization Coeff', step=0.1, minval=0)
hllength = input.int(10, 'Highest and Lowest Length', minval=1)
src = ta.highest(high, hllength)
srcl = ta.lowest(low, hllength)
highlighting = input(title='Highlighter On/Off ?', defval=true)
mav = input.string(title='Moving Average Type', defval='VAR', options=['SMA', 'EMA', 'WMA', 'DEMA', 'TMA', 'VAR', 'WWMA', 'ZLEMA', 'TSF', 'HULL'])
Var_Func(src, length) =>
    valpha = 2 / (length + 1)
    vud1 = src > src[1] ? src - src[1] : 0
    vdd1 = src < src[1] ? src[1] - src : 0
    vUD = math.sum(vud1, 9)
    vDD = math.sum(vdd1, 9)
    vCMO = nz((vUD - vDD) / (vUD + vDD))
    VAR = 0.0
    VAR := nz(valpha * math.abs(vCMO) * src) + (1 - valpha * math.abs(vCMO)) * nz(VAR[1])
    VAR
VAR = Var_Func(src, length)
DEMA = 2 * ta.ema(src, length) - ta.ema(ta.ema(src, length), length)
Wwma_Func(src, length) =>
    wwalpha = 1 / length
    WWMA = 0.0
    WWMA := wwalpha * src + (1 - wwalpha) * nz(WWMA[1])
    WWMA
WWMA = Wwma_Func(src, length)
Zlema_Func(src, length) =>
    zxLag = length / 2 == math.round(length / 2) ? length / 2 : (length - 1) / 2
    zxEMAData = src + src - src[zxLag]
    ZLEMA = ta.ema(zxEMAData, length)
    ZLEMA
ZLEMA = Zlema_Func(src, length)
Tsf_Func(src, length) =>
    lrc = ta.linreg(src, length, 0)
    lrc1 = ta.linreg(src, length, 1)
    lrs = lrc - lrc1
    TSF = ta.linreg(src, length, 0) + lrs
    TSF
TSF = Tsf_Func(src, length)
HMA = ta.wma(2 * ta.wma(src, length / 2) - ta.wma(src, length), math.round(math.sqrt(length)))
Var_Funcl(srcl, length) =>
    valphal = 2 / (length + 1)
    vud1l = srcl > srcl[1] ? srcl - srcl[1] : 0
    vdd1l = srcl < srcl[1] ? srcl[1] - srcl : 0
    vUDl = math.sum(vud1l, 9)
    vDDl = math.sum(vdd1l, 9)
    vCMOl = nz((vUDl - vDDl) / (vUDl + vDDl))
    VARl = 0.0
    VARl := nz(valphal * math.abs(vCMOl) * srcl) + (1 - valphal * math.abs(vCMOl)) * nz(VARl[1])
    VARl
VARl = Var_Funcl(srcl, length)
DEMAl = 2 * ta.ema(srcl, length) - ta.ema(ta.ema(srcl, length), length)
Wwma_Funcl(srcl, length) =>
    wwalphal = 1 / length
    WWMAl = 0.0
    WWMAl := wwalphal * srcl + (1 - wwalphal) * nz(WWMAl[1])
    WWMAl
WWMAl = Wwma_Funcl(srcl, length)
Zlema_Funcl(srcl, length) =>
    zxLagl = length / 2 == math.round(length / 2) ? length / 2 : (length - 1) / 2
    zxEMADatal = srcl + srcl - srcl[zxLagl]
    ZLEMAl = ta.ema(zxEMADatal, length)
    ZLEMAl
ZLEMAl = Zlema_Funcl(srcl, length)
Tsf_Funcl(srcl, length) =>
    lrcl = ta.linreg(srcl, length, 0)
    lrc1l = ta.linreg(srcl, length, 1)
    lrsl = lrcl - lrc1l
    TSFl = ta.linreg(srcl, length, 0) + lrsl
    TSFl
TSFl = Tsf_Funcl(srcl, length)
HMAl = ta.wma(2 * ta.wma(srcl, length / 2) - ta.wma(srcl, length), math.round(math.sqrt(length)))

getMA(src, length) =>
    ma = 0.0
    if mav == 'SMA'
        ma := ta.sma(src, length)
        ma

    if mav == 'EMA'
        ma := ta.ema(src, length)
        ma

    if mav == 'WMA'
        ma := ta.wma(src, length)
        ma

    if mav == 'DEMA'
        ma := DEMA
        ma

    if mav == 'TMA'
        ma := ta.sma(ta.sma(src, math.ceil(length / 2)), math.floor(length / 2) + 1)
        ma

    if mav == 'VAR'
        ma := VAR
        ma

    if mav == 'WWMA'
        ma := WWMA
        ma

    if mav == 'ZLEMA'
        ma := ZLEMA
        ma

    if mav == 'TSF'
        ma := TSF
        ma

    if mav == 'HULL'
        ma := HMA
        ma
    ma


getMAl(srcl, length) =>
    mal = 0.0
    if mav == 'SMA'
        mal := ta.sma(srcl, length)
        mal

    if mav == 'EMA'
        mal := ta.ema(srcl, length)
        mal

    if mav == 'WMA'
        mal := ta.wma(srcl, length)
        mal

    if mav == 'DEMA'
        mal := DEMAl
        mal

    if mav == 'TMA'
        mal := ta.sma(ta.sma(srcl, math.ceil(length / 2)), math.floor(length / 2) + 1)
        mal

    if mav == 'VAR'
        mal := VARl
        mal

    if mav == 'WWMA'
        mal := WWMAl
        mal

    if mav == 'ZLEMA'
        mal := ZLEMAl
        mal

    if mav == 'TSF'
        mal := TSFl
        mal

    if mav == 'HULL'
        mal := HMAl
        mal
    mal

MAvg = getMA(src, length)
fark = MAvg * percent * 0.01
longStop = MAvg - fark
longStopPrev = nz(longStop[1], longStop)
longStop := MAvg > longStopPrev ? math.max(longStop, longStopPrev) : longStop
shortStop = MAvg + fark
shortStopPrev = nz(shortStop[1], shortStop)
shortStop := MAvg < shortStopPrev ? math.min(shortStop, shortStopPrev) : shortStop
dir = 1
dir := nz(dir[1], dir)
dir := dir == -1 and MAvg > shortStopPrev ? 1 : dir == 1 and MAvg < longStopPrev ? -1 : dir
MT = dir == 1 ? longStop : shortStop
HOTT = MAvg > MT ? MT * (200 + percent) / 200 : MT * (200 - percent) / 200
HOTTC = color.blue
MAvgl = getMAl(srcl, length)
farkl = MAvgl * percent * 0.01
longStopl = MAvgl - farkl
longStopPrevl = nz(longStopl[1], longStopl)
longStopl := MAvgl > longStopPrevl ? math.max(longStopl, longStopPrevl) : longStopl
shortStopl = MAvgl + farkl
shortStopPrevl = nz(shortStopl[1], shortStopl)
shortStopl := MAvgl < shortStopPrevl ? math.min(shortStopl, shortStopPrevl) : shortStopl
dirl = 1
dirl := nz(dirl[1], dirl)
dirl := dirl == -1 and MAvgl > shortStopPrevl ? 1 : dirl == 1 and MAvgl < longStopPrevl ? -1 : dirl
MTl = dirl == 1 ? longStopl : shortStopl
LOTT = MAvgl > MTl ? MTl * (200 + percent) / 200 : MTl * (200 - percent) / 200
LOTTC = color.red
HOTTLine = plot(nz(HOTT[2]), title='HOTT', color=color.new(HOTTC, 0), linewidth=2, style=plot.style_line)
LOTTLine = plot(nz(LOTT[2]), title='LOTT', color=color.new(LOTTC, 0), linewidth=2, style=plot.style_line)
FillColor = highlighting ? color.new(#9915FF, 80) : na
fill(HOTTLine, LOTTLine, title='Highligter', color=FillColor)
color1 = close > HOTT[2] ? #00FFFF : close < LOTT[2] ? #FF00FF : na
barcolor(color1)
alertcondition(ta.crossover(close, HOTT[2]), title='Price Crossover Alarm', message='PRICE OVER HOTT - BUY SIGNAL!')
alertcondition(ta.crossunder(close, LOTT[2]), title='Price Crossunder Alarm', message='PRICE UNDER LOTT - SELL SIGNAL!')

link: HIGH-and-LOW-Optimized-Trend-Tracker-HOTT-LOTT/

Bewerbungen

1
Entwickler 1
Bewertung
(271)
Projekte
366
71%
Schlichtung
18
33% / 44%
Frist nicht eingehalten
14
4%
Frei
Veröffentlicht: 14 Beispiele
2
Entwickler 2
Bewertung
(322)
Projekte
499
67%
Schlichtung
5
40% / 0%
Frist nicht eingehalten
4
1%
Frei
Veröffentlicht: 8 Beispiele
3
Entwickler 3
Bewertung
(152)
Projekte
228
80%
Schlichtung
22
27% / 50%
Frist nicht eingehalten
11
5%
Frei
Veröffentlicht: 24 Artikel, 1882 Beispiele
4
Entwickler 4
Bewertung
(294)
Projekte
469
39%
Schlichtung
100
41% / 23%
Frist nicht eingehalten
77
16%
Beschäftigt
Veröffentlicht: 2 Beispiele
5
Entwickler 5
Bewertung
(7)
Projekte
8
50%
Schlichtung
0
Frist nicht eingehalten
0
Frei
Veröffentlicht: 1 Beispiel
6
Entwickler 6
Bewertung
(574)
Projekte
945
47%
Schlichtung
309
58% / 27%
Frist nicht eingehalten
125
13%
Frei
Ähnliche Aufträge
I need someone to build a Telegram bot signal provider for IQ Option that works like this: 🔔 NEW SIGNAL! 🎫 Trade: 🇬🇧 GBP/USD 🇺🇸 (OTC) ⏳ Timer: 2 minutes ➡️ Entry: 5:29 PM 📈 Direction: BUY 🟩 ↪️ Martingale Levels: Level 1 → 5:31 PM Level 2 → 5:33 PM Level 3 → 5:35 PM Requirements: The bot should send signals automatically to Telegram. Must support multiple trades and martingale levels. I will test it for 3 days
Fix issue on script Enhanced version of the Red Magma Algo Market Structure indicator with sophisticated) alert system that prevents fake alerts and provides visual/audio notifications based on the trading flowchart logic. What it does (aligned with your chart): · Detects Break of Structure (BOS) after a consolidation · Marks demand zones: o Low-risk zone = origin of impulse (deep pullback) o
Indicator 30 - 150 USD
Has anyone heard of the tradingview indicator trend pulse pro v2? I'm looking for something similar if you haven't heard about feel free to Google it and get back to me
Looking for NinjaTrader 8 Developer I’m looking for an experienced NinjaTrader 8 (C#) developer to build a custom indicator based on the Jackson–Dalton Trading System . Requirements: Jackson zones (Z1 / Z2 / Z3) VWAP with volume-weighted standard deviation Session volume profile (POC, VAH, VAL) Day-type classification Configurable alerts Support for BTC/USDT and ETH/USDT Clean, modular code with full source Optional
I am looking for an experienced MQL5 developer to work on a two-phase project based on a clearly defined intraday trading strategy for DAX (M1 timeframe) . The project is intentionally divided into two distinct phases . Phase 1 is mandatory and consists of developing a custom indicator to visually evaluate and validate the strategy. Phase 2 is optional and will consist of developing the Expert Advisor , only if Phase
I need a professional in Pine Script Indicators that can develop my strategies into Indicators that will work on Tradingview platform Here is where you can get information about the strategies i want to develop https://chartprime.com/strategies
Hello i just funded 3 mt5 accounts i want them all seperate on my desktop and install a tradingpanel that i bought on mql5 market, should be an easy job but i tried it and it didnt work so if anyone can do it we can go on any desk or skype and fix it
Hello I want a code for my MetaTrader 4 and MetaTrader 5 indicator I want to give my indicator with license to my students this indicator will reach to my google sheet and if user MetaTrader 4 or Metatrader 5 account number doesnt reach to Exired date, it will go on work. other wise it freeze the indicator drawings or delete the indicator from chart the google sheet is like that
I am looking for an experienced MQL5 developer to modify and enhance my existing Expert Advisor, "Gold Levels Trader". The current version has a low win rate (~30%) and issues with ATR-based Stop Loss execution. I want to replace the current "pips drop/rise" logic with Fibonacci Retracement levels for entry signals, implement a Daily Drawdown Limit , and add Pending Orders functionality
I’m looking for a developer to create a PINESCRIPT of the MetaTrader 5 (MT5) version of the Cap Channel indicator. The free version of this indicator is publicly available at the following link for reference: https://tradingfinder.com/products/indicators/mt5/cap-channel-trading-free-download/ While the basic functionality is accessible, I specifically need a custom-built version with full access to the source

Projektdetails

Budget
30+ USD
Ausführungsfristen
von 1 bis 4 Tag(e)