Indicators Conversion PROREALCODE-MT4

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Indicators Conversion PROREALCODE-MT4

Postby Nika van Flier » Fri Jan 10, 2020 6:57 am

Hello,
Would you be so kind to convert these two Proreal indicators to mt4?
The first one is an intraday levels indicator and the second is a trend signal.
I would be very grateful if you could do it.

Levels:
Code: Select all
defparam drawonlastbaronly = true
 
if valorhora =1 then
 
if opentime= 080000 then
Pa=open
x = barindex
endif
endif
if valorhora =2 then
if opentime = 020000 then
Pa=open
x= barindex
endif
endif
if pa=0 then
pa = open
endif
P = pa
S1 = P / 1.00236
S2 = P / 1.00382
S3 = P / 1.005
s4 = P / 1.00618
s5 = P / 1.00762
s6 = P / 1.01
s7 = P / 1.01236
s8 = P / 1.01382
s9 = P / 1.015
r1 = P * 1.00236
rr2 = P * 1.00382
r3 = P * 1.005
r4 = P * 1.00618
r5 = P * 1.00762
r6 = P * 1.01
r7 = P * 1.01236
r8 = P * 1.01382
r9 = P * 1.015
 
 
//vertical offset to draw text correctly over horizontal lines
Voffset = 2*pipsize
 
 
DRAWTEXT("PA",barindex-3,p+Voffset,SansSerif,Bold,16)coloured(153,153,0)
DRAWTEXT("s1",barindex-3,s1+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("s2",barindex-3,s2+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("S3",barindex-3,s3+Voffset,SansSerif,Bold,16)coloured(153,0,0)
DRAWTEXT("s4",barindex-3,S4+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("s5",barindex-3,S5+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("S6",barindex-3,S6+Voffset,SansSerif,Bold,16)coloured(153,0,0)
DRAWTEXT("s7",barindex-3,S7+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("s8",barindex-3,S8+Voffset,SansSerif,Bold,12)coloured(153,0,0)
DRAWTEXT("S9",barindex-3,S9+Voffset,SansSerif,Bold,16)coloured(153,0,0)
DRAWTEXT("r1",barindex-3,r1+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("r2",barindex-3,rr2+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("R3",barindex-3,r3+Voffset,SansSerif,Bold,16)coloured(0,153,0)
DRAWTEXT("r4",barindex-3,r4+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("r5",barindex-3,r5+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("R6",barindex-3,r6+Voffset,SansSerif,Bold,16)coloured(0,153,0)
DRAWTEXT("r7",barindex-3,r7+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("r8",barindex-3,r8+Voffset,SansSerif,Bold,12)coloured(0,153,0)
DRAWTEXT("R9",barindex-3,r9+Voffset,SansSerif,Bold,16)coloured(0,153,0)
 
 
 
drawsegment(barindex,p,x,p) coloured(0,0,0)
drawsegment(barindex,s1,x,s1) coloured(153,0,0)
drawsegment(barindex,s2,x,s2) coloured(153,0,0)
drawsegment(barindex,s3,x,s3) coloured(153,0,0)
drawsegment(barindex,S4,x,S4) coloured(153,0,0)
drawsegment(barindex,S5,x,S5) coloured(153,0,0)
drawsegment(barindex,S6,x,S6) coloured(153,0,0)
drawsegment(barindex,S7,x,S7) coloured(153,0,0)
drawsegment(barindex,S8,x,S8) coloured(153,0,0)
drawsegment(barindex,S9,x,S9) coloured(153,0,0)
drawsegment(barindex,r1,x,r1) coloured(0,153,0)
drawsegment(barindex,rr2,x,rr2) coloured(0,153,0)
drawsegment(barindex,R3,x,R3) coloured(0,153,0)
drawsegment(barindex,r4,x,r4) coloured(0,153,0)
drawsegment(barindex,r5,x,r5) coloured(0,153,0)
drawsegment(barindex,R6,x,R6) coloured(0,153,0)
drawsegment(barindex,R7,x,R7) coloured(0,153,0)
drawsegment(barindex,R8,x,R8) coloured(0,153,0)
drawsegment(barindex,R9,x,R9) coloured(0,153,0)
 
RETURN


Trend:
Code: Select all
pvi = PositiveVolumeIndex(close)

pvim = ExponentialAverage[m](pvi)

pvimax = highest[90](pvim)

pvimin = lowest[90](pvim)

oscp = (pvi - pvim) * 100/ (pvimax - pvimin)

nvi =NegativeVolumeIndex(close)

nvim = ExponentialAverage[m](nvi)

nvimax = highest[90](nvim)

nvimin = lowest[90](nvim)

azul = (nvi - nvim) * 100/ (nvimax - nvimin)

xmf = MoneyFlowIndex[14]

OB1 = (BollingerUp[25](TotalPrice) + BollingerDown[25](TotalPrice)) / 2
OB2 = BollingerUp[25](TotalPrice) - BollingerDown[25](TotalPrice)

BollOsc = ((TotalPrice - OB1) / OB2 ) * 100

xrsi = rsi [14](TotalPrice)

STOC = Stochastic[21,3](TotalPrice)

marron = (xrsi + xmf + BollOsc + (STOC / 3))/2

verde = marron + oscp

media = ExponentialAverage[m](marron)

bandacero= 0

return verde COLOURED(102,255,102) as "verde", marron COLOURED(255,204,153) as "marron", marron COLOURED(51,0,0) as "lmarron", azul COLOURED(0,255,255) as "azul", verde COLOURED(0,102,0) as "lineav", azul COLOURED(0,0,102) as "lazul", media COLOURED(255,0,0) as "media", bandacero COLOURED(0,0,0) as "cero"


Thank you so much.
Nika van Flier
 
Posts: 2
Joined: Fri Jan 10, 2020 5:30 am

Re: Indicators Conversion PROREALCODE-MT4

Postby Apprentice » Sat Jan 11, 2020 7:16 am

Your request is added to the development list.
Development reference 541.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36437
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Indicators Conversion PROREALCODE-MT4

Postby Nika van Flier » Sat Jan 11, 2020 10:52 am

Thank you very much Apprentice
Nika van Flier
 
Posts: 2
Joined: Fri Jan 10, 2020 5:30 am



Return to Indicator and Signal Requests

Who is online

Users browsing this forum: Majestic-12 [Bot] and 6 guests