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

Re: [amibroker] How to get this indicator working on intraday charts



PureBytes Links

Trading Reference Links

works fine for me

On 10/24/05, TradersOnline <tradersonline@xxxxxxxxx> wrote:
>
>
> Hi
>
>
>
> I have been using Historical Trendlines and breakouts indicator on eod
> charts and it works excellent but it is not working on intraday charts.
>
> Can any help me in getting it working on intraday charts.
>
>
>
> Indicator:
>
>
>
> /*HISTORICAL TRENDLINES and BREAKOUTS, by D. Tsokakis, Oct2003*/
>
>
>
> x = Cum(1);
>
>
>
> per = 3;// CALIBRATE THE ZIG() SENSITIVITY
>
>
>
> s1=L;s11=H;
>
>
>
> pS = TroughBars( s1, per, 1 ) == 0;
>
>
>
> endt=SelectedValue(ValueWhen( pS, x ,1));
>
>
>
> startt=SelectedValue(ValueWhen( pS, x ,2));
>
>
>
> dtS =endt-startt;
>
>
>
> endS = SelectedValue((ValueWhen( pS, s1,1) ));
>
>
>
> startS = SelectedValue(( ValueWhen( pS, s1 ,2)));
>
>
>
> aS = (endS-startS)/dtS;bS = endS;
>
>
>
> trendlineS = aS * ( x -endt ) + bS;//SUPPORT LINE
>
>
>
> pR = PeakBars( s11, per, 1 ) == 0;
>
>
>
> endt1= SelectedValue(ValueWhen( pR, x, 1));
>
>
>
> startt1=SelectedValue(ValueWhen( pR, x, 2 ));
>
>
>
> dtR =endt1-startt1;
>
>
>
> endR = SelectedValue(ValueWhen( pR, s11, 1 ) );
>
>
>
> startR = SelectedValue( ValueWhen( pR, s11, 2 ));
>
>
>
> aR = (endR-startR)/dtR;bR = endR;
>
>
>
> trendlineR = aR * ( x -endt1 ) + bR;//RESISTANCE LINE
>
>
>
> first=Min(startt,startt1);Last=Max(endt,endt1);
>
>
>
> d=10;// INCREASE d TO EXTEND THE LINES
>
>
>
> bullishbreakout=x>endt1 AND x<last+d AND Cross(C,trendlineR);
>
>
>
> bearishbreakout=x>endt AND x<last+d AND Cross(trendlineS,C);
>
>
>
> Plot(C,"Close",IIf(bullishbreakout,colorBrightGreen,IIf
>
>
>
> (bearishbreakout,colorRed,colorBlack)),64);
>
>
>
> Plot(IIf(x>=first -d AND x<=Last+d,trendlineS,-
>
>
>
> 1e10),"Support",colorBrightGreen,1);
>
>
>
> Plot(IIf(x>=first-d AND x<=Last+d,trendlineR,-
>
>
>
> 1e10),"Resistance",colorRed,1);
>
>
>
>
>
> Rupesh
>
>
>
>
>
>
>
>
>
>
>
> 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
>
>  Visit your group "amibroker" on the web.
>
>  To unsubscribe from this group, send an email to:
>  amibroker-unsubscribe@xxxxxxxxxxxxxxx
>
>  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
>  To unsubscribe from this group, send an email to:
>  amibroker-unsubscribe@xxxxxxxxxxxxxxx
>
>  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
>  Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
> ________________________________
>
>
>
> --
> Internal Virus Database is out-of-date.
> Checked by AVG Anti-Virus.
> Version: 7.0.344 / Virus Database: 267.11.14/129 - Release Date: 10/11/2005
>


--
Cheers
Graham
AB-Write >< Professional AFL Writing Service
Yes, I write AFL code to your requirements
http://e-wire.net.au/~eb_kavan/ab_write.htm


------------------------ Yahoo! Groups Sponsor --------------------~--> 
Make a difference. Find and fund world-changing projects at GlobalGiving.
http://us.click.yahoo.com/PcNrnD/PbOLAA/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/