Thanks Mike. That makes sense.

--- In amibroker@yahoogroups.com, "Mike" <sfclimb...@...> wrote:
>
> Not all scripts are written with an intent to backtest. Looking into the 
> future can be a useful visual cue for charting.
> 
> Even so, forward looking functions can still be used in scripts intended for 
> backtesting. You just need to add logic to delay acting on any signals until 
> they would have actually been seen. There's an example of delayed Zig in the 
> user library
> 
> http://www.amibroker.com/library/detail.php?id=353
> 
> Mike
> 
> --- In amibroker@yahoogroups.com, "ozzyapeman" <zoopfree@> wrote:
> >
> > Doesn't Zig look into the future? 
> > 
> > And this may be a dumb question - but if it does look into the future, then 
> > of what use is it for trading systems, since it can never give realistic 
> > results in backtests? Any function that looks into the future will 
> > obviously give near perfect results, that cannot be replicated in live 
> > trading.
> > 
> > 
> > 
> > --- In amibroker@yahoogroups.com, reinsley <reinsley@> wrote:
> > >
> > > 
> > > Hi,
> > > 
> > > This formula can inspire you ...
> > > 
> > > Best regards
> > > 
> > > //Patterns Wave
> > > 
> > > _SECTION_BEGIN("Patterns Wave");
> > > Change = Param("Wave Period",7,0,100,1);
> > > SupResA = Param("Sup-Res A Period",20,0,100,1);
> > > SupResB = Param("Sup-Res B Period",25,0,100,1);
> > > 
> > > Res1 = ParamColor("Resistance High", colorRed );
> > > Res2 = ParamColor("Resistance Low", colorDarkRed );
> > > Sup1 = ParamColor("Support High", colorDarkGreen );
> > > Sup2 = ParamColor("Support Low", colorBrightGreen );
> > > 
> > > procedure PlotShapeAt( x, y, shape, shift )
> > > {
> > > PlotShapes( IIf( BarIndex() == x, shape, 0 ), colorWhite, 0, y,
> > > shift );
> > > }
> > > 
> > > bi = BarIndex();
> > > sbi = SelectedValue( bi );
> > > GraphXSpace = 2;
> > > Plot( Zig( C, Change ), "", colorWhite, styleThick );
> > > upshift = 15;
> > > if( SelectedValue( PeakBars( C, Change ) < TroughBars( C, Change ) ) )
> > > {
> > > pt1 = PeakBars( C, Change, 1 ) == 0 ;
> > > pt2 = TroughBars( C, Change, 1 ) == 0 ;
> > > }
> > > else
> > > {
> > > pt1 = TroughBars( C, Change, 1 ) == 0 ;
> > > pt2 = PeakBars( C, Change, 1 ) == 0 ;
> > > upshift = -upshift;
> > > }
> > > bpt1 = SelectedValue( ValueWhen( pt1, bi ) );
> > > bpt2 = SelectedValue( ValueWhen( pt2, bi ) );
> > > bpt3 = SelectedValue( ValueWhen( pt1, bi, 2 ) );
> > > bpt4 = SelectedValue( ValueWhen( pt2, bi, 2 ) );
> > > bpt5 = SelectedValue( ValueWhen( pt1, bi, 3 ) );
> > > bpt6 = SelectedValue( ValueWhen( pt2, bi, 3 ) );
> > > PlotShapeAt( bpt1, C, shapeDigit5, upshift );
> > > PlotShapeAt( bpt2, C, shapeDigit4, -upshift );
> > > PlotShapeAt( bpt3, C, shapeDigit3, upshift );
> > > PlotShapeAt( bpt4, C, shapeDigit2, -upshift );
> > > PlotShapeAt( bpt5, C, shapeDigit1, upshift );
> > > 
> > > Plot( C, "", colorWhite, styleThick + styleCandle);
> > > _SECTION_END();
> > > 
> > > 
> > > cvanhaesendonck a écrit :
> > > >  
> > > > 
> > > > My pleasure:
> > > > http://books.google.be/books?id=GZtlA991lNYC&pg=PT105&lpg=PT105&dq=demark+d-wave&source=bl&ots=GsizxkEprO&sig=W4nDwR5okjqzZXGvugIwH589EKU&hl=fr&ei=eW7DSvCkI83A-Qb04v3uCw&sa=X&oi=book_result&ct=result&resnum=6&ved=0CBwQ6AEwBQ#v=onepage&q=demark%20
> > > >  
> > > > <http://books.google.be/books?id=GZtlA991lNYC&pg=PT105&lpg=PT105&dq=demark+d-wave&source=bl&ots=GsizxkEprO&sig=W4nDwR5okjqzZXGvugIwH589EKU&hl=fr&ei=eW7DSvCkI83A-Qb04v3uCw&sa=X&oi=book_result&ct=result&resnum=6&ved=0CBwQ6AEwBQ#v=onepage&q=demark%20>
> > > > 
> > > > Basically, time and sequence constraints are added; something like this 
> > > > TD1 (that is EW1 D-wave) is completed when pre-TD1 conditions are 
> > > > filled; so here we go based on Perl interpretation on the link above:
> > > > 
> > > > PreTD1= C==LLV(C,21);
> > > > TD1= follows PreTD1 and C== HHV(C,13) ;
> > > > TD2= follows TD1 and C==LLV(C,8);
> > > > TD3= follows ...and.. C==HHV(C,21);
> > > > TD4= follows ...and..C==LLV(C,13);
> > > > TD5= follows ...and..C==HHV(C,34);
> > > > TDA= follows ...and..C==LLV(C,13);
> > > > TDB= follows ...and..C==HHV(C,8);
> > > > TDC= follows ...and..C==LLV(C,21);
> > > > 
> > > > I have to admit I have some difficulty to code at least a Plotshape 
> > > > thing pointing a Digit1, 2, 3 on the chart to show the d-waves but 
> > > > hopefully someone here will b e able to do this??
> > > > 
> > > > Carl
> > > > 
> > > > --- In amibroker@yahoogroups.com <mailto:amibroker%40yahoogroups.com>, 
> > > > Keith McCombs <kmccombs@> wrote:
> > > >  >
> > > >  > Carl --
> > > >  > Can you summarize those rules and post them here?
> > > >  > -- Keith
> > > >  >
> > > >  > cvanhaesendonck wrote:
> > > >  > >
> > > >  > >
> > > >  > > Tom Demark has made a great job simplifying Elliott wave count and
> > > >  > > making it more objective thanks to a straight rule set. Those rules
> > > >  > > can be summarized in few lines. Has anyone ever developed AFL 
> > > > coding
> > > >  > > on this. AFL library contains some Demark codes (now public domain)
> > > >  > > but nothing on d-waves.
> > > >  > >
> > > >  > > Carl
> > > >  > >
> > > >  > >
> > > >  >
> > > > 
> > > >
> > >
> >
>


Reply via email to