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

[amibroker] Re: Adjust Volumn Histogram for Spikes ?



PureBytes Links

Trading Reference Links

Many thanks Rick - that works like a charm .....


Dean 



--- In amibroker@xxxxxxxxxxxxxxx, "Rick" <rrogers@xxx> wrote:
>
> Dean:
> here is a formula that i use, hope it helps
> Rick :
> 
> VolFactor =  2.5  ; // use this to adjust the amount to truncate
> Per1 = 50 ; 
> 
> MaxVol = VolFactor*MA(Volume,Per1);
> 
> col1 = IIf( Close >= Ref( Close, -1 ), colorBlack,colorRed);
> 
> col2 = IIf(Volume > MaxVol,colorBlue, colorLightGrey);
> 
> VolTrunc = IIf(Volume > MaxVol,MaxVol,Volume);
> 
> Plot (VolTrunc, "VolTrunc", col1, styleHistogram );
> 
> Plot( VolTrunc, "VolDot", col2, 
> styleDots|styleNoLine|styleNoLabel|styleNoTitle); /* this plots 
blue 
> dot above truncated volume, grey above others*/
> 
> Plot(int(MA(Volume,Per1)),"MA",colorBlue,styleLine);
> Plot( 0, "", colorBlack, styleNoLine|styleNoLabel);   /* causes 
graph 
> to scale to 0*/
> GraphXSpace = 2;
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "troll" <deanhodgins@> wrote:
> >
> > Intraday charts often show volumn spike at day's
> > end or 1.00pm as day /programmed positions closed. 
> > This can result in "distorted" volumn histogram that 
> > requires high upper value with resulting loss of 
> > detail for previous part of day.
> > 
> > I'm trying to think of way to "dampen" effect of vol spike or
> > adjust scale somehow but not sure how to approach. 
> > 
> > Couldn't find any previous references on board.
> > 
> > As always gratefull any suggestions or pointers.
> > 
> > 
> > 
> > 
> > Dean H.
> >
>