[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [amibroker] Fibonacci Cluster Calculations?



PureBytes Links

Trading Reference Links

   
 Hello,
        Check out code by Dimitris (oblique Fibonacci) if thats what u
want :
          
       //Fibonacci Retracements Oblique:

x = Cum(1);per = 5;s1=L;s11=H;
pS = TroughBars( s1, per, 1 ) == 0;
endt= LastValue(ValueWhen( pS, x, 1 ));
startt=LastValue(ValueWhen( pS, x, 2 ));
dtS =endt-startt;
endS = LastValue(ValueWhen( pS, s1, 1 ) );
startS = LastValue( ValueWhen( pS, s1, 2 ));
aS = (endS-startS)/dtS;bS = endS;
trendlineS = aS * ( x -endt ) + bS;
SU = IIf(x>startt-1,trendlineS,-1e10);
Plot(SU,"\nSU",colorYellow,styleThick);
pR = PeakBars( s11, per, 1 ) == 0;
endt1= LastValue(ValueWhen( pR, x, 1 ));
startt1=LastValue(ValueWhen( pR, x, 2 ));
firstt1=LastValue(ValueWhen( pR, x, 3 ));
dtR =endt1-startt1;
endR = LastValue(ValueWhen( pR, s11, 1 ) );
startR = LastValue( ValueWhen( pR, s11, 2 ));
aR = (endR-startR)/dtR;
bR = endR;
trendlineR = aR * ( x -endt1 ) + bR;
RE = IIf(x>startT1-1,trendlineR,-1e10);
//Plot(RE,"RE",colorOrange,styleThick);
Plot(C,"C",colorBlack,64);b=BarIndex();
X1=ValueWhen(Cum(IsTrue(SU))==1,b);
Y1=ValueWhen(b==X1,SU);
X2=LastValue(b);Y2=LastValue(SU);
SLOPE=(Y2-Y1)/(X2-X1);
YP=LastValue(Highest(SU/SU*H));//Plot(yp,"",1,1);
XP=ValueWhen(H==YP,b);
HL0=YP+SLOPE*(b-XP);
DIST=ValueWhen(H==YP,H-SU);
HL1=YP-0.382*DIST+SLOPE*(b-XP);Plot(HL1,"\n0.382",colorTurquoise,1);
HL2=YP-0.5*DIST+SLOPE*(b-XP);Plot(HL2,"\n0.500",colorRed,8);
HL3=YP-0.618*DIST+SLOPE*(b-XP);Plot(HL3,"\n0.618",colorIndigo,1);
HL4=YP-0.786*DIST+SLOPE*(b-XP);Plot(HL4,"\n0.786",colorGold,1);
Plot((HL1/HL1)*HL0,"\nRE",colorYellow,styleThick);
GraphXSpace=2;
  
 ++++++++++++++++++++++++++++++
      


  --- N !!

--- Natasha !! <dynomitedoll_ddd@xxxxxxxxx> wrote:
> 
>   Hi,
>      What is a 3 bar + pull back and direction?:
>  
> Here is your trendline:
>     
>    +++++++++++   
> x = Cum(1);per = 5;s1=L;s11=H;
> 
> pS = TroughBars( s1, per, 1 ) == 0;
> 
> endt= LastValue(ValueWhen( pS, x, 1 ));
> 
> startt=LastValue(ValueWhen( pS, x, 2 ));
> 
> dtS =endt-startt;
> 
> endS = LastValue(ValueWhen( pS, s1, 1 ) );
> 
> startS = LastValue( ValueWhen( pS, s1, 2 ));
> 
> aS = (endS-startS)/dtS;bS = endS;
> 
> trendlineS = aS * ( x -endt ) + bS;
> 
> SU = IIf(x>startt-1,trendlineS,-1e10);
> 
> Plot(SU,"\nSU",colorYellow,styleThick);
> 
> Plot(C,"close",colorBlack,64);
> 
>         +++++++++++++
> 
> Explain in detail what u want and i will give it a go today being
> Sunday.
>  
> --- N !!  
>     
> Jerry Gress <pleasenospamplease@xxxxxxxxxxx> wrote:
> 
> Hi All,
> 
> Does anybody have any direction to automatically draw Fibonacci
> cluster
> levels? In a nut shell take a trend (any time frame) draw a trend
> line then
> calculate possible support/resistance based on 3 + bar pull backs in
> said
> trend line using fib numbers!! Not your standard Fib drawing tool.
> Then AB
> would draw those lines.
> 
> Jerry Gress
> Stockton, Ca.
> 
> 
> Warm regards, 
> Natasha !
>  
>   
>  
> 
> 
> 
> 
> 
> 		
> ---------------------------------
> Do you Yahoo!?
>  Make Yahoo! your home page   

Warm regards, 
Natasha !
 
  
 






__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


------------------------ Yahoo! Groups Sponsor --------------------~--> 
What would our lives be like without music, dance, and theater?
Donate or volunteer in the arts today at Network for Good!
http://us.click.yahoo.com/Tcy2bD/SOnJAA/cosFAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.html

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/