Page 20 of 33

Re: QQE indicators for MT4

Posted: Tue Oct 26, 2021 3:14 am
by mrtools
Sagiv wrote: Mon Oct 25, 2021 5:44 pm Dear Mrtools is it possible to convert this QQE script from TV pine script.

The script is needed for trading highly success HMA & FLI & QQE strategy. ( I hope its not against the rules to share the youtube video for this strategy -

This is the script made by Mihkel00 and the Original was made by Glaz -

Code: Select all

//@version=4
//By Glaz, Modified
//
study("QQE MOD")
RSI_Period = input(6, title='RSI Length')
SF = input(5, title='RSI Smoothing')
QQE = input(3, title='Fast QQE Factor')
ThreshHold = input(3, title="Thresh-hold")
//

src = input(close, title="RSI Source")
//

//
Wilders_Period = RSI_Period * 2 - 1


Rsi = rsi(src, RSI_Period)
RsiMa = ema(Rsi, SF)
AtrRsi = abs(RsiMa[1] - RsiMa)
MaAtrRsi = ema(AtrRsi, Wilders_Period)
dar = ema(MaAtrRsi, Wilders_Period) * QQE

longband = 0.0
shortband = 0.0
trend = 0

DeltaFastAtrRsi = dar
RSIndex = RsiMa
newshortband = RSIndex + DeltaFastAtrRsi
newlongband = RSIndex - DeltaFastAtrRsi
longband := RSIndex[1] > longband[1] and RSIndex > longband[1] ? 
   max(longband[1], newlongband) : newlongband
shortband := RSIndex[1] < shortband[1] and RSIndex < shortband[1] ? 
   min(shortband[1], newshortband) : newshortband
cross_1 = cross(longband[1], RSIndex)
trend := cross(RSIndex, shortband[1]) ? 1 : cross_1 ? -1 : nz(trend[1], 1)
FastAtrRsiTL = trend == 1 ? longband : shortband
////////////////////


length = input(50, minval=1, title="Bollinger Length")
mult = input(0.35, minval=0.001, maxval=5, step=0.1, title="BB Multiplier")
basis = sma(FastAtrRsiTL - 50, length)
dev = mult * stdev(FastAtrRsiTL - 50, length)
upper = basis + dev
lower = basis - dev
color_bar = RsiMa - 50 > upper ? #00c3ff : RsiMa - 50 < lower ? #ff0062 : color.gray


//
// Zero cross
QQEzlong = 0
QQEzlong := nz(QQEzlong[1])
QQEzshort = 0
QQEzshort := nz(QQEzshort[1])
QQEzlong := RSIndex >= 50 ? QQEzlong + 1 : 0
QQEzshort := RSIndex < 50 ? QQEzshort + 1 : 0
//  

Zero = hline(0, color=color.white, linestyle=hline.style_dotted, linewidth=1)

////////////////////////////////////////////////////////////////

RSI_Period2 = input(6, title='RSI Length')
SF2 = input(5, title='RSI Smoothing')
QQE2 = input(1.61, title='Fast QQE2 Factor')
ThreshHold2 = input(3, title="Thresh-hold")

src2 = input(close, title="RSI Source")
//

//
Wilders_Period2 = RSI_Period2 * 2 - 1


Rsi2 = rsi(src2, RSI_Period2)
RsiMa2 = ema(Rsi2, SF2)
AtrRsi2 = abs(RsiMa2[1] - RsiMa2)
MaAtrRsi2 = ema(AtrRsi2, Wilders_Period2)
dar2 = ema(MaAtrRsi2, Wilders_Period2) * QQE2
longband2 = 0.0
shortband2 = 0.0
trend2 = 0

DeltaFastAtrRsi2 = dar2
RSIndex2 = RsiMa2
newshortband2 = RSIndex2 + DeltaFastAtrRsi2
newlongband2 = RSIndex2 - DeltaFastAtrRsi2
longband2 := RSIndex2[1] > longband2[1] and RSIndex2 > longband2[1] ? 
   max(longband2[1], newlongband2) : newlongband2
shortband2 := RSIndex2[1] < shortband2[1] and RSIndex2 < shortband2[1] ? 
   min(shortband2[1], newshortband2) : newshortband2
cross_2 = cross(longband2[1], RSIndex2)
trend2 := cross(RSIndex2, shortband2[1]) ? 1 : cross_2 ? -1 : nz(trend2[1], 1)
FastAtrRsi2TL = trend2 == 1 ? longband2 : shortband2


//
// Zero cross
QQE2zlong = 0
QQE2zlong := nz(QQE2zlong[1])
QQE2zshort = 0
QQE2zshort := nz(QQE2zshort[1])
QQE2zlong := RSIndex2 >= 50 ? QQE2zlong + 1 : 0
QQE2zshort := RSIndex2 < 50 ? QQE2zshort + 1 : 0
//  

hcolor2 = RsiMa2 - 50 > ThreshHold2 ? color.silver :
   RsiMa2 - 50 < 0 - ThreshHold2 ? color.silver : na
plot(FastAtrRsi2TL - 50, title='QQE Line', color=color.white, transp=0, linewidth=2)
plot(RsiMa2 - 50, color=hcolor2, transp=50, title='Histo2', style=plot.style_columns)

Greenbar1 = RsiMa2 - 50 > ThreshHold2
Greenbar2 = RsiMa - 50 > upper

Redbar1 = RsiMa2 - 50 < 0 - ThreshHold2
Redbar2 = RsiMa - 50 < lower
plot(Greenbar1 and Greenbar2 == 1 ? RsiMa2 - 50 : na, title="QQE Up", style=plot.style_columns, color=#00c3ff, transp=0)
plot(Redbar1 and Redbar2 == 1 ? RsiMa2 - 50 : na, title="QQE Down", style=plot.style_columns, color=#ff0062, transp=0)
P.S
I have been testing this strategy with your custom made FLI & HMA that I found here, but the QQE is totally different.
Am looking at it , not sure if I can do it but will try, no promises.

Re: QQE indicators for MT4

Posted: Tue Oct 26, 2021 3:28 am
by Sagiv
mrtools wrote: Tue Oct 26, 2021 3:14 am Am looking at it , not sure if I can do it but will try, no promises.
Thank you!

You are so kind mrtools, thank you for trying!

Re: QQE indicators for MT4

Posted: Tue Oct 26, 2021 4:36 pm
by Jimmy
Sagiv wrote: Mon Oct 25, 2021 5:44 pm Dear Mrtools is it possible to convert this QQE script from TV pine script.

The script is needed for trading highly success HMA & FLI & QQE strategy. ( I hope its not against the rules to share the youtube video for this strategy -
Sagiv, please mate can you wrap your code next time by using the "Code" button before posting? Those type of long code-posts are a trip.

Please see below for a guide:
Image

Re: QQE indicators for MT4

Posted: Tue Oct 26, 2021 7:19 pm
by Sagiv
Jimmy wrote: Tue Oct 26, 2021 4:36 pm Sagiv, please mate can you wrap your code next time by using the "Code" button before posting? Those type of long code-posts are a trip.

Please see below for a guide:
Sure thing Jimmy, I Didn't know about it

Re: QQE indicators for MT4

Posted: Tue Oct 26, 2021 8:44 pm
by Jimmy
Sagiv wrote: Tue Oct 26, 2021 7:19 pm Sure thing Jimmy, I Didn't know about it
Thank you brother 🙂

Re: QQE indicators for MT4

Posted: Thu Oct 28, 2021 10:28 pm
by Sagiv
mrtools wrote: Tue Oct 26, 2021 3:14 am Am looking at it , not sure if I can do it but will try, no promises.
Hi Mrtools,

I hope you are doing great!

Just wanted to remind you about my QQE request.

Thanks a lot for trying!

Re: QQE indicators for MT4

Posted: Fri Jan 28, 2022 5:21 am
by kvak
Sorry Iam trying this file convert to candles, but for now without succes.
But make a candle version of this ...

Adding MTF to this QQE indicator

Posted: Fri Mar 11, 2022 5:37 am
by kenshin281180#
Hello Fellow Traders,

I was wondering if one of you fine individuals would be able to add a mtf aspect to this indicator. Everything else is fine, I'd just like to see if any of you can add that function so I don't have to switch to another tf. I appreciate your time and expertise.

Thank you in advance

Re: Adding MTF to this QQE indicator

Posted: Fri Mar 11, 2022 5:48 am
by mrtools
kenshin281180# wrote: Fri Mar 11, 2022 5:37 am Hello Fellow Traders,

I was wondering if one of you fine individuals would be able to add a mtf aspect to this indicator. Everything else is fine, I'd just like to see if any of you can add that function so I don't have to switch to another tf. I appreciate your time and expertise.

Thank you in advance
Have you tried this thread qqe indicators there are some newer versions with mtf and other things.

Re: Adding MTF to this QQE indicator

Posted: Fri Mar 11, 2022 6:26 am
by kenshin281180#
mrtools wrote: Fri Mar 11, 2022 5:48 am Have you tried this thread qqe indicators there are some newer versions with mtf and other things.
Hi Sir, yes I've tried some different iterations but they don't have the same settings as the files I've attached. I just like the simplicity of it and how it looks. Hope that makes sense