Page 1844 of 2041

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 6:49 am
by mrtools
traderokey wrote: Sat Apr 29, 2023 2:52 am Hi Mrtools;

Could you please upgrade this RSI bands indicator with the following features;
  • Add on/off button
  • Add all prices
  • Add all averages

The indicator in its current form gives me the ability to add moving averages to the indicator subwindow. I'll want the upgraded version to still retain this feature. Thanks for your help.


!!! Rsi bands.mq4
Try here

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 12:34 pm
by mrtools
Chickenspicy wrote: Sat Apr 29, 2023 3:56 am My bad there was two codes posted for it
This looks more like it

Code: Select all

//Super ADX Coded by Karthikmarar. Blog. www.karthikmarar.blogspot.com email. karthikmarar@yahoo.com
//System based on the free clone availablein Metatrader
// Public release for personal use only.
//Please do not commercialize this indicator in its original or modified form.
_SECTION_BEGIN("Super ADX Clone");

WavePeriod = Param("WAVE PERIOD",10,5,30,1);
AvgPeriod = Param("Smoothing Period",21,9,45,1);
VAR1 = EMA(C, WavePeriod);
VAR2 = (abs(H+C+L)/ 3.0 - VAR1);
VAR3 = EMA(VAR2,WavePeriod);
VAR4 = IIf(VAR3 > 0,((H+L+C) / 3.0 - VAR1) / (0.015 * VAR3),0);
VAR5 = EMA(VAR4, AvgPeriod);
VAR6 = MA(VAR5, 4);
JA = IIf (VAR5 >= VAR6 AND Ref(VAR5,-1) <= Ref(VAR6,-1) AND VAR5 <= -50, 1,0);
JB = IIf (VAR5 <= VAR6 AND Ref(VAR5,-1) >= Ref(VAR6,-1) AND VAR5 >= 53,1,0);
AX1 = ADX(14);
AX2 = Ref(AX1,-1);
AX3 = Ref(AX1,-2);
JX = MACD(12,26);
JXS = Signal(12,26,9);
JX1 = Ref(JX,-1);
JX1S = Ref(JXS,-1);
ADXFL1 = AX2 > 35 AND AX1 < AX2 AND AX2 > AX3;
ADXFL2 = AX1 < 10 AND AX1 > AX2 AND AX2 < AX3;
MACDFL1 = IIf (JX > JX1 AND JXS <= JX1S,1,0);
MACDFL2 = IIf (JX < JX1 AND JXS >= JX1S,1,0);
MACDFL  = MACDFL1 OR MACDFL2;
YB = IIf(ADXFL1 AND (JA == 1 OR JB == 1),1,0); //YELLOW BAR
WBMACD = IIf(ADXFL1 AND MACDFL ,1,0);
WB = IIf(ADXFL1,1,0);
RB = IIf(ADXFL2,1,0);
MBC = WB OR WBMACD;
TB = Sum(MBC, 16);
TBARS = TB == 3 AND Ref(TB,-1)==2;
WriteVal(TBars);
PL = IIf(TBARS,40,IIf(YB,35,IIf(WBMACD,30,IIf(WB,25,IIf(RB,20,Null)))));
BCOLOR = IIf(tbars,colorCustom12,IIf(YB,colorYellow,IIf(WBMACD,colorViolet,IIf(WB,colorWhite,IIf(RB,colorRed,colorBlack)))));
SetBarFillColor( BCOLOR);
yb1=IIf(yb,30,0);
wb1=IIf(wb,25,0);
wbmacd1 =IIf(wbmacd,20,0);
rb1 = IIf(rb,15,0);
PlotOHLC(0,pl,0,pl,"",BCOLOR,styleCandle|styleThick);
PlotShapes( IIf(tbars ,shapeSmallSquare,Null), colorCustom12,0,40,0);
PlotShapes( IIf(yb ,shapeSmallSquare,Null), colorYellow,0,35,0);
PlotShapes( IIf(wbmacd,shapeSmallSquare,Null), colorViolet,0,30,0);
PlotShapes( IIf(wb,shapeSmallSquare,Null), colorWhite,0,25,0);
PlotShapes( IIf(rb,shapeSmallSquare,Null), colorRed,0,20,-0);

//========================= Header with Comments ====================================
if( Status("action") == actionIndicator ) 
(
Title = EncodeColor(colorWhite)+ "SUPER ADX Clone" + " - " +  Name() + " - " + EncodeColor(colorRed)+ Interval(2) + EncodeColor(colorWhite) +
 "  - " + Date() +" - " +EncodeColor(colorLime)+ "Volume= "+WriteVal(V)+"--"+EncodeColor(colorYellow)+
("\n Super ADX Alert :  ")+WriteIf(yb,EncodeColor(colorYellow)+" White Bar + Trend Wave",
WriteIf(tbars,EncodeColor(colorCustom12)+" White Bar + Trend Wave",
WriteIf(WBmacd,EncodeColor(colorViolet)+"White Bar + MACD, EXPECT REVERSAL",WriteIf(WB,EncodeColor(colorWhite)+"White Bar - EXIT",
WriteIf(rb,EncodeColor(colorRed)+"Red Bar - Big Move","" ))))));


Filter = tbars==1 OR yb ==1 OR wbmacd==1 OR wb ==1 OR rb==1;
AddColumn( tbars, "TBARS",bkgndColor  = colorCustom12 );
AddColumn( yb, "YB",bkgndColor  = colorYellow );
AddColumn( wbmacd, "WBMACD",bkgndColor  = colorViolet );
AddColumn( wb, "WB",bkgndColor  = colorWhite );
AddColumn( rb, "RB",bkgndColor  = colorRed );



_SECTION_END(); 
Image
I did a version in the old Tsd forum days will try and do another one.

ps) don't have the code anymore but found an old screenshot.

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 3:31 pm
by tkhanfx
mrtools wrote: Sat Apr 29, 2023 3:17 am Buffer #12 is the trend buffer it sends the buy/sell signals for the indicator to determine the colors. 1 = up trend and -1 = down trend.
May be am missing something.. But i just don't see the 1/-1 values for the signal arrows anywhere

Could it please kindly be shown in a pic where is the 1/-1 trend values? from what i see #12 buffer is not 1/-1 values, they are market price value for the lines

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 3:36 pm
by mrtools
tkhanfx wrote: Sat Apr 29, 2023 3:31 pm May be am missing something.. But i just don't see the 1/-1 values for the signal arrows anywhere

Could it please kindly be shown in a pic where is the 1/-1 trend values? from what i see #12 buffer is not 1/-1 values, they are market price value for the lines
Will you be posting the EA here when you are done with it?

Code: Select all


SetIndexBuffer(12,valc, INDICATOR_CALCULATIONS);
valc[i] = (r>0) ? (val[i]>val[i+1]) ? 1 : (val[i]<val[i+1]) ? -1 : valc[i+1] : 0;

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 4:27 pm
by tkhanfx
mrtools wrote: Sat Apr 29, 2023 3:36 pm Will you be posting the EA here when you are done with it?

Code: Select all


SetIndexBuffer(12,valc, INDICATOR_CALCULATIONS);
valc[i] = (r>0) ? (val[i]>val[i+1]) ? 1 : (val[i]<val[i+1]) ? -1 : valc[i+1] : 0;
Will try not to disappoint you

For now its still experimental with using chat-gpt/mql4programmer as the main developers and trying to develop an understanding of coding

Endless gratitude for all your help Mr.Tools

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 4:32 pm
by Gethsemane
Found an interesting indicator on Tradingview, if it can be converted.
It plots HH/LL/LH/HL as histogram, pretty neat.

https://se.tradingview.com/script/KMVvr ... owest-Low/
Image

Code: Select all

//@version=2
study("HH&LL") // highest high & lowest low
length=input(20)
ww=input(false,title="use adaptive OS/OB ?")
qq=input(true,title="use backround signal color?")
his=input(true,title="Show Histogram?")
useCurrentRes = input(true, title="Use Current Chart Resolution?")
resCustom = input(title="Use Different Timeframe? (Uncheck Box Above).", type=resolution, defval="D")
res = useCurrentRes ? period : resCustom
HHH =iff( high > high[1], (high - lowest( high, length )) /( highest( high, length ) - lowest( high, length ) ), 0 ) 
LLL = iff( low < low[1],( highest( low, length ) - low ) /( highest( low, length ) - lowest( low, length ) ), 0 ) 
HHSa = ema( HHH, length ) * 100 
LLSa = ema( LLL, length ) * 100 
HHS = security(tickerid, res,HHSa)
LLS= security(tickerid, res, LLSa)
aa=plot( HHS, "HHS" ,color=blue,transp=0) 
bb=plot( LLS, "LLS" ,color=red,transp=0) 	
hln=input(60)
lln=input(10)
smo=input(50,"Bands Filter length")
hs=highest(max(HHS,LLS),50)
lw=lowest(min(LLS,HHS),50)
mh=ema(hs,20)
RMSa= sum( mh*mh, smo)
RMS= avg(sqrt(RMSa/smo),hln)
al=ww?RMS:hln
ms=ema(lw,20)
MSa= sum( ms*ms, smo)
MS= avg(sqrt(MSa/smo),lln)
bs=ww?MS:lln
col=HHS>al and HHS[2]<HHS[1] and HHS[1]>HHS and LLS<bs?1:0
cor=LLS>al and LLS[2]<LLS[1] and LLS[1]>LLS and HHS<bs?1:0
con=HHS<bs and HHS[2]>HHS[1] and HHS[1]<HHS and LLS>al?1:0
cod=LLS<bs and LLS[2]>LLS[1] and LLS[1]<LLS and HHS>al?1:0
bc=col or cod?red: cor or con?green:na
a=plot(al,style=cross,color=black,transp=50)
b=plot(bs,style=cross,color=black,transp=50)
df=abs(HHS-LLS)
cl=df>55?red : df<25?green :orange
plot(his?df:na,color=cl,style=histogram,linewidth=2,transp=75)
plot(HHS>al?HHS:na,style=histogram,histbase=60,color=red)
plot(LLS>al?LLS:na,style=histogram,histbase=60,color=red)
plot(LLS<bs?LLS:na,style=histogram,histbase=10,color=green)
plot(HHS<bs?HHS:na,style=histogram,histbase=10,color=green)
bgcolor(qq?bc:na,transp=80)

Re: MT4 Indicator requests and ideas

Posted: Sat Apr 29, 2023 5:53 pm
by Panzon
Can someone modify this ea?
Just want changes in orders.
I want when any hedge trade active, previous trade will be close.
you can see it in pic..

Thanks
Suhas

Blacklist him!

Posted: Sat Apr 29, 2023 7:13 pm
by moey_dw
mrtools wrote: Sat Apr 29, 2023 3:36 pm Will you be posting the EA here when you are done with it?
tkhanfx wrote: Sat Apr 29, 2023 4:27 pm Will try not to disappoint you
That sounds suspiciously like a big fat "NO" from him so I say we blacklist this guy from any further help in future....

Re: Blacklist him!

Posted: Sat Apr 29, 2023 7:20 pm
by Panzon
moey_dw wrote: Sat Apr 29, 2023 7:13 pm That sounds suspiciously like a big fat "NO" from him so I say we blacklist this guy from any further help in future....
Is this for me?

Re: Blacklist him!

Posted: Sat Apr 29, 2023 7:24 pm
by moey_dw
Panzon wrote: Sat Apr 29, 2023 7:20 pm Is this for me?
Is your name tkhanfx?