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

[amibroker] Re: Weekly VFI



PureBytes Links

Trading Reference Links

Larry
It was not my code - except for the suggestion for the last line.
But as to your problem, the code is as I have it (and it plots 
properly on my computer).  The only thing I can think of is that the 
variable "wc" conflicts with a plug-in somewhere on your system.
Try changing "wc" to something else (in all places where it exists - 
you'll find it in the cutoff line.

Rick
--- In amibroker@xxxxxxxxxxxxxxx, "larypowell" <larypowell@xxx> wrote:
>
> Rick 
>  
> I am trying the VFI you showed, I am getting a syntax error 
> /* Weekly Volume Flow Indicator */
> 
> _SECTION_BEGIN("Weekly VFI");
> 
> WC = TimeFrameCompress( Close, inWeekly ); < This is the line I am 
having
> problem with.  In the help section and in the post below the "wc" 
is lower
> case, my keeps showing upper case and I am getting Error 31, syntax 
error,
> expecting "("
> 
> Any help would be appreciated.  
> 
> Thanks, Larry
> 
>  
>   _____  
> 
> From: amibroker@xxxxxxxxxxxxxxx [mailto:amibroker@xxxxxxxxxxxxxxx] 
On Behalf
> Of ricko8294_98
> Sent: 02/02/2006 7:11 PM
> To: amibroker@xxxxxxxxxxxxxxx
> Subject: [amibroker] Re: Weekly VFI
> 
> 
> Instead of your last line should you not use 
> Plot( V, "", colorSeaGreen, styleNoLabel | styleHistogram | 
> styleOwnScale );
> 
> Rick
> 
> 
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "brhelpdesk" <cassianoqs@> wrote:
> >
> > I'm trying to create a Weekly VFI in a daily chart but I don't 
kwon 
> > why the results are wrong.
> > 
> > /* Weekly Volume Flow Indicator */
> > 
> > _SECTION_BEGIN("Weekly VFI");
> > 
> > wc = TimeFrameCompress( Close, inWeekly ); 
> > wv = TimeFrameCompress( abs(V), inWeekly ); 
> > wa = TimeFrameCompress( Avg, inWeekly );
> > Period = Param("VFI Period",26,26,1300,1);
> > Coef=0.2;
> > VCoef=Param("Max. vol. cutoff",2.5,2.5,50,1);
> > inter = log(wa)-log(Ref(wa,-1));
> > Vinter = StDev(inter,30);
> > Cutoff=Coef*Vinter*wc;
> > Vave=Ref(MA(wv,Period),-1);
> > Vmax=Vave*Vcoef;
> > Vc=Min(wv,VMax);
> > MF=wa-Ref(wa,-1);
> > VCP=IIf(MF>Cutoff,VC,IIf(MF<-Cutoff,-VC,0));
> > VFI1=Sum(VCP,Period)/Vave;
> > VFI=EMA(VFI1,3);
> > EVFI= EMA( VFI, 7 );
> > vfi = TimeFrameExpand( vfi, inWeekly ); // expand for display 
> > evfi = TimeFrameExpand( evfi, inWeekly ); // expand for display 
> > Plot( VFI, "VFI", colorYellow, styleThick );
> > Plot( EVFI, "EMA7 of VFI", colorOrange, styleDashed );
> > Plot( 0, "", colorSeaGreen, styleNoLabel );
> > 
> > _SECTION_END();
> >
>







------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/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/