Independent Indicator 1
{Chaos AO }
{ Chaos Awsome Oscillator - measures momentum } { A very close approximation of MFI } { Plot as histogram }
ma(MP(),5,S) - ma(MP(),34,S);
Independent Indicator 2
{Chaos AO } { Chaos Awsome Oscillator - measures momentum } { A very close approximation of MFI } { Plot as histogram } n1 := input("Shorter moving average",5,1); n2 := input("Longer moving average",34,1); Green:=IF( ma(MP(),n1,S) - ma(MP(),n2,S) >=0,ma(MP(),n1,S) - ma(MP(),n2,S),undefined); Red:=IF( ma(MP(),n1,S) - ma(MP(),n2,S) <0,ma(MP(),n1,S) - ma(MP(),n2,S) ,undefined); [name=Green; linestyle=bar; width=4] [color=Green; name=Greenlight] If(Green>=0,Green,undefined); [name=Red; linestyle=bar; width=4] [color=Orange; name=Redlight2] If(Green>=0 AND Green <Hist(Green,1), Green,undefined);
[name=Red2; linestyle=bar; width=4] [color=Red; name=Redlight] If(Red<0, Red,undefined); [name=Red4; linestyle=bar; width=4] [color=Lime; name=Redlight2] If(Red <0 AND Red >Hist(Red,1), Red,undefined);
Independent Indicator 3
ns := input("Time periods",1,1); nl := input("Time periods",14,1); {Chaos AO } { Chaos Awsome Oscillator Adapted PLDot - measures momentum } { A very close approximation of MFI } { Plot as histogram }
TaPLDot:=(((hist(h,0)+hist(Low,0)+hist(C,0))/2)+((hist(h,1)+hist(Low,1)+hist(C,1))/2))/2; ma(TaPLDot,ns,S) - ma(TaPLDot,nl,S);
{Chaos AO with signals} { Chaos Awsome Oscillator - measures momentum CMD adapted to match Metastock indicator } { A very close approximation of MFI } { Plot as histogram } Red:=If(ma(MP(),5,S) - ma(MP(),34,S)<Ref(ma(MP(),5,S) - ma(MP(),34,S),-1) OR (Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)<Ref(ma(MP(),5,S) - ma(MP(),34,S),-2) AND ma(MP(),5,S) - ma(MP(),34,S)=Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)),ma(MP(),5,S) - ma(MP(),34,S),0); Green:=If(ma(MP(),5,S) - ma(MP(),34,S)>Ref(ma(MP(),5,S) - ma(MP(),34,S),-1) OR (Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)>Ref(ma(MP(),5,S) - ma(MP(),34,S),-2) AND ma(MP(),5,S) - ma(MP(),34,S)=Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)),ma(MP(),5,S) - ma(MP(),34,S),0); AOcrossoverBuy:= Green>0 and Ref(Green,-1)< 0; AOsaucerBuy:= Green>0 and Green> Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Green>0 and Ref(Red,-1)>0; AOUnderlineBuy:= Green<0 and Green> Ref(Red,-1); AOUnderlinesecondBuy:= Green<0 and Green> Ref(Green,-1) and Green> Ref(Green,-2) and Ref(Red,-3)<0; AOcrossunderSell:= Red<0 and Ref(Red,-1)>0 ; AOOverlineSell:= Red>0 and Red< Ref(Green,-1); AOUnderlineSell:= Red<0 and Red> Ref(Green,-1); AOsaucerSell:= Red<0 and Red< Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Red<0 and Ref(Green,-1)<0;
Red; Green; { Markers } [name=CB; linestyle=marker; marker=type15; tooltip=" AOcrossoverBuy "] [color=green] AOcrossoverBuy; { Markers } [name=SauB; linestyle=marker; marker=type17; colour=green;tooltip=" AOsaucerBuy "] [color=green] AOsaucerBuy; { Markers } [name=UB; linestyle=marker; marker=type15; tooltip=" AOUnderlineBuy"] [color=green] AOUnderlineBuy; { Markers } [name=U2B; linestyle=marker; marker=type15; tooltip=" AOUnderlinesecondBuy"] [color=green] AOUnderlinesecondBuy; { Markers } [name=CS; linestyle=marker; marker=type15; tooltip=" AOcrossunderSell"] [color=red] AOcrossunderSell;
{ Markers } [name=OS; linestyle=marker; marker=type28; tooltip=" AOUnderlinesecondBuy"] [color=Red] AOOverlineSell; { Markers } [name=US; linestyle=marker; marker=type29; tooltip=" AOUnderlineSell"] [color=Red] AOUnderlineSell; { Markers } [name=SauS; linestyle=marker; marker=type17; colour=green;tooltip=" AOsaucerSell "] [color=green] AOsaucerSell;
Independent Indicator 5
{Chaos AO with signals} S1 := inputma("Method",SIMPLE); n1 := input("Shorter moving average",5,1); n2 := input("Longer moving average",34,1); methodroc := inputroc("Mode"); Red:=If(ma(MP(),n1,S1) - ma(MP(),n2,S1)<Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1) OR (Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)<Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-2) AND ma(MP(),n1,S1) - ma(MP(),n2,S1)=Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)),ma(MP(),n1,S1) - ma(MP(),n2,S1),0); Green:=If(ma(MP(),n1,S1) - ma(MP(),n2,S1)>Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1) OR (Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)>Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-2) AND ma(MP(),n1,S1) - ma(MP(),n2,S1)=Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)),ma(MP(),n1,S1) - ma(MP(),n2,S1),0); {Awesome oscillator} AOcrossoverBuy:= Green>0 and Ref(Green,-1)<0; AOsaucerBuy:= Green>0 and Green> Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Green>0 and Ref(Red,-1)>0; AOUnderlineBuy:= Green<0 and Green> Ref(Red,-1); AOUnderlinesecondBuy:= Green<0 and Green> Ref(Green,-1) and Green> Ref(Green,-2) and Ref(Red,-3)<0; AOcrossunderSell:= Red<0 and Ref(Red,-1)>0 ; AOOverlineSell:= Red>0 and Red< Ref(Green,-1); AOUnderlineSell:= Red<0 and Red> Ref(Green,-1); AOsaucerSell:= Red<0 and Red< Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Red<0 and Ref(Green,-1)<0; [name=DownMomentum; linestyle=Bar; width=4; color=Red;] Red; [name=UpMomentum; linestyle=Bar; width=4; color=Royal Blue;] Green;
{Markers} [name=Cb;linestyle=marker;marker=long;fontsize=6;Color=Green;textalign=below,center;tooltip="AOcrossoverBuy "] AOcrossoverBuy;
[name=SauB;linestyle=marker;marker=long;colour=green;tooltip="AOsaucerBuy "] AOsaucerBuy; [name=Ub;linestyle=marker;marker=long;tooltip="AOUnderlineBuy"] AOUnderlineBuy; [name=Ub2;linestyle=marker;marker=long;tooltip="AOUnderlinesecondBuy"] AOUnderlinesecondBuy; [name=Cs;linestyle=marker;marker=short;Color=Red;textalign=Above,center;tooltip="AOcrossunderSell"] AOcrossunderSell;
[name=s2;linestyle=marker;marker=short;tooltip="AOOverlineSell"] AOOverlineSell; [name=US;linestyle=marker;marker=short;tooltip="AOUnderlineSell"] AOUnderlineSell; [name=SauS;linestyle=marker;marker=short;tooltip="AOsaucerSell "]
AOsaucerSell;
Independent Indicator 6
{Chaos AO with variable inputs} S1 := inputma("Method",SIMPLE); n1 := input("Shorter moving average",5,1); n2 := input("Longer moving average",34,1); methodroc := inputroc("Mode"); Red:=If(ma(MP(),n1,S1) - ma(MP(),n2,S1)<Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1) OR (Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)<Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-2) AND ma(MP(),n1,S1) - ma(MP(),n2,S1)=Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)),ma(MP(),n1,S1) - ma(MP(),n2,S1),0); Green:=If(ma(MP(),n1,S1) - ma(MP(),n2,S1)>Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1) OR (Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)>Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-2) AND ma(MP(),n1,S1) - ma(MP(),n2,S1)=Ref(ma(MP(),n1,S1) - ma(MP(),n2,S1),-1)),ma(MP(),n1,S1) - ma(MP(),n2,S1),0); {Awesome oscillator} AOcrossoverBuy:= Green>0 and Ref(Green,-1)<0; AOsaucerBuy:= Green>0 and Green> Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Green>0 and Ref(Red,-1)>0; AOUnderlineBuy:= Green<0 and Green> Ref(Red,-1); AOUnderlinesecondBuy:= Green<0 and Green> Ref(Green,-1) and Green> Ref(Green,-2) and Ref(Red,-3)<0; AOcrossunderSell:= Red<0 and Ref(Red,-1)>0 ; AOOverlineSell:= Red>0 and Red< Ref(Green,-1); AOUnderlineSell:= Red<0 and Red> Ref(Green,-1); AOsaucerSell:= Red<0 and Red< Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Red<0 and Ref(Green,-1)<0; [name=DownMomentum; linestyle=Bar; width=4; color=Red;] Red; [name=UpMomentum; linestyle=Bar; width=4; color=Royal Blue;] Green;
{Markers} [name=Cb;linestyle=marker;marker=long;fontsize=6;Color=Green;textalign=below,center;tooltip="AOcrossoverBuy "] AOcrossoverBuy;
[name=SauB;linestyle=marker;marker=long;colour=green;tooltip="AOsaucerBuy "] AOsaucerBuy; [name=Ub;linestyle=marker;marker=long;tooltip="AOUnderlineBuy"] AOUnderlineBuy; [name=Ub2;linestyle=marker;marker=long;tooltip="AOUnderlinesecondBuy"] AOUnderlinesecondBuy; [name=Cs;linestyle=marker;marker=short;Color=Red;textalign=Above,center;tooltip="AOcrossunderSell"] AOcrossunderSell;
[name=s2;linestyle=marker;marker=short;tooltip="AOOverlineSell"] AOOverlineSell; [name=US;linestyle=marker;marker=short;tooltip="AOUnderlineSell"] AOUnderlineSell; [name=SauS;linestyle=marker;marker=short;tooltip="AOsaucerSell "] AOsaucerSell;
Independent Indicator 7
{Chaos Zones } { Chaos Alligator CMD Developed Refer Chapter 7} { Plot as histogram } green := If(ma(MP(),5,S) - ma(MP(),34,S)<Ref(ma(MP(),5,S) - ma(MP(),34,S),-1) OR (Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)<Ref(ma(MP(),5,S) - ma(MP(),34,S),-2) AND ma(MP(),5,S) - ma(MP(),34,S)=Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)),ma(MP(),5,S) - ma(MP(),34,S),0); green1 :=If(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S)<Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1) OR (Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1)<Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-2) AND Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S)=Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1)),Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),0); red :=If(ma(MP(),5,S) - ma(MP(),34,S)>Ref(ma(MP(),5,S) - ma(MP(),34,S),-1) OR (Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)>Ref(ma(MP(),5,S) - ma(MP(),34,S),-2) AND ma(MP(),5,S) - ma(MP(),34,S)=Ref(ma(MP(),5,S) - ma(MP(),34,S),-1)),ma(MP(),5,S) - ma(MP(),34,S),0); red1:= If(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S)>Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1) OR (Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1)>Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-2) AND Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S)=Ref(Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),-1)),Fml("CMD Chaos AO") - ma(Fml("CMD Chaos AO"),5,S),0); redtwo:=red and red1; greentwo:=green and green1; Greyone:=red and green1; Greytwo:=red1 and green;
redtwo; greentwo; Greyone; Greytwo;
Price chart indicators Independent Indicator 8
method := inputma("Method",SIMPLE); n := input("Longer Time period",14,1);
{Chaos AO with signals} { Chaos Awsome Oscillator - measures momentum CMD adapted to match Metastock indicator } { A very close approximation of MFI } { Plot as histogram }
{This is TRApldot but to save all the recoding called Pldot} Pldot:=(((hist(h,0)+hist(Low,0)+hist(C,0))/3)+((hist(h,1)+hist(Low,1)+hist(C,1))/3))/2; Red:=If(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD)<Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1) OR (Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1)<Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-2) AND ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD)=Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1)),ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),0); Green:=If(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD)>Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1) OR (Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1)>Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-2) AND ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD)=Ref(ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),-1)),ma(PLDOT,1,METHOD) - ma(PLDOT,n,METHOD),0); AOcrossoverBuy:= Green>0 and Ref(Green,-1)< 0; AOsaucerBuy:= Green>0 and Green> Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Green>0 and Ref(Red,-1)>0; AOUnderlineBuy:= Green<0 and Green> Ref(Red,-1); AOUnderlinesecondBuy:= Green<0 and Green> Ref(Green,-1) and Green> Ref(Green,-2) and Ref(Red,-3)<0; AOcrossunderSell:= Red<0 and Ref(Red,-1)>0 ; AOOverlineSell:= Red>0 and Red< Ref(Green,-1); AOUnderlineSell:= Red<0 and Red> Ref(Green,-1); AOsaucerSell:= Red<0 and Red< Ref(Green,-1) and Ref(Green,-1)< Ref(Green,-2) or Red<0 and Ref(Green,-1)<0; [target=Price; linestyle=PriceColor;] [name=Slowing; color=Red; name=Slowing] if(Red,1,undefined); [name=Momentum; color=Royal Blue; name=Momentum] if(Green,1,undefined);
Independent Indicator 9
{Chaos Fractals} [description="Some Fractal Patterns showing the High or Low value instead of a marker."; citation= "'Fractal Pattern from Trading Chaos 2nd Ed, pp 137-138' or New Trading Dimensions pp 67 to 70"; author=Bill Williams & Justine Gregory-Williams and Bill Williams respectively; ] [target=Price;] High1a := Ref(HIGH,-3); High1 := Ref(HIGH,-2); High2 := Ref(HIGH,-1); High3 := Ref(HIGH,0); High4 := Ref(HIGH,1); High5 := Ref(HIGH,2); Low1a := Ref(LOW,-3); Low1 := Ref(LOW,-2); Low2 := Ref(LOW,-1); Low3 := Ref(LOW,0); Low4 := Ref(LOW,1); Low5 := Ref(LOW,2); FractalUp:= (High3 > High1) AND (High3 > High2) AND (High3 > High4) AND (High3 > High5); FractalUp1:= (High3 > High1a) AND (High3 > High1) AND (High3 = High2) AND (High3 > High4) AND (High3 > High5); FractalU:=If(FractalUp OR FractalUp1,1,undefined); FractalDown:= (Low3 < Low1) AND (Low3 < Low2) AND(Low3 < Low4) AND (Low3 < Low5); FractalDown1:= (Low3 < Low1a) AND (Low3 < Low1) AND (Low3 = Low2) AND(Low3 < Low4) AND (Low3 < Low5); FractalD:=If(FractalDown OR FractalDown1,1,undefined);
HoldLevelPeriod := Input("Hold Level Period",15,1); [linestyle=points; color=blue; width=5]
UpFractal:=If(FractalU, H*1.0000005,undefined); FrU:=ValueWhen(1,UpFractal,UpFractal); FrUb:=If(H < FrU and barssince(UpFractal)< HoldLevelPeriod, FrU,undefined); FrUb; { Fractal Lows } [color =indian red] DownFractal:= If(FractalD, L*0.9999995,undefined); FrD:=ValueWhen(1,DownFractal,DownFractal); FrDb:= If(L > FrD and barssince(DownFractal)<HoldLevelPeriod,FrD,undefined); FrDb; { Markers } [name =HH; linestyle=marker; marker=type2] SignalUp:= If(Hist(FrUb,1) and H > FrU,FrU,undefined); SignalUp; [name =LL; linestyle=marker; marker=type1] SignalDown:= If(Hist(FrDb,1) and L < FrD,FrD,undefined); SignalDown; [linestyle=Text; textalign=centre, Above,; color=Red] if(FractalU, " " + h, undefined); High; [linestyle=Text; textalign=centre,Below; color=Green] if(FractalD, "" + l, undefined); Low;
------------- BC User since June 2007
|