PureBytes Links
Trading Reference Links
|
Hello,
Seems like someone may have already presented something similar.
Anyway here's a simple AFL code to display N bar candlesticks.
Aequalsz
Nbars = Param("N bars",1,1,10,1);
ibar = BarCount-1;
for( i = BarCount-Nbars; i > 0; i=i-Nbars )
{
Mopen[ibar] = Open[i];
Mclose[ibar] = Close[i+Nbars-1];
Hs = 0.0;
Ls = 100000.0;
for(j=i; j < i+Nbars; j++)
{
if(High[j] > Hs)
{
Hs = High[j];
}
if(Low[j] < Ls)
{
Ls = Low[j];
}
}
Mhigh[ibar] = Hs;
Mlow[ibar] = Ls;
ibar = ibar - 1;
}
GraphXSpace = 1;
PlotOHLC(Mopen,Mhigh,Mlow,Mclose,"Mult day bars",c
olorWhite,styleCandle);
------------------------ Yahoo! Groups Sponsor --------------------~-->
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/GHeqlB/TM
--------------------------------------------------------------------~->
Check AmiBroker web page at:
http://www.amibroker.com/
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.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/
|