Print Page | Close Window

The Better Volume Indicator

Printed From: BullCharts Forum
Category: BullCharts
Forum Name: BullScript
Forum Discription: Technical discussion related specifically to the BullScript programming language.
URL: http://www.bullcharts.com.au/forum/forum_posts.asp?TID=694
Printed Date: 03 May 2024 at 3:01am
Software Version: Web Wiz Forums 9.69 - http://www.webwizforums.com


Topic: The Better Volume Indicator
Posted By: Tanaka
Subject: The Better Volume Indicator
Date Posted: 22 Mar 2011 at 1:11am

There is a very good volume indicator called the "The Better Volume Indicator". Information can be found at http://emini-watch.com/free-stuff/volume-indicator/

The example in the link which I have pasted below is written for TradeStation. I have searched the net for hours trying to find a Metastock code but can't. Does anyone know if this can be coded for Bullcharts?


Inputs: LowVol(True), ClimaxUp(True), ClimaxDown(True), Churn(True)…

Variables: BarColor(Cyan);

 

BarColor = Color;

 

If BarType > 1 or UseUpTicks = False then begin

If C > O and Range <> 0 then Value1 = (Range/

(2*Range+O-C))*UpTicks;

If C < O and Range <> 0 then Value1 = ((Range+C-O)

(2*Range+C-O))*UpTicks;

If C = O then Value1 = 0.5*UpTicks;

Value2 = UpTicks-Value1;

End;

 

If BarType <= 1 and UseUpTicks then begin

Value1 = UpTicks;

Value2 = DownTicks;

End;

 

Value3 = AbsValue(Value1+Value2);

Value4 = Value1*Range;

Value5 = (Value1-Value2)*Range;

Value6 = Value2*Range;

Value7 = (Value2-Value1)*Range;

If Range <> 0 then begin

Value8 = Value1/Range;

Value9 = (Value1-Value2)/Range;

Value10 = Value2/Range;

Value11 = (Value2-Value1)/Range;

Value12 = Value3/Range;

End;

 

Etc.


Thanks in advance,


Tanaka




Replies:
Posted By: maximo
Date Posted: 22 Mar 2011 at 4:28pm
That appears to be only part of the indicator for tick bars, coloured Cyan.
 
Here is the full Better Volume Indicator from their site, recoded in Bullscript.
 
Enjoy!
 

[description="Better Volume Indicator - http://emini-watch.com/free-stuff/volume-indicator/"]

Range := High - Low;

Value1 := Volume;

Value2 := Volume*Range;

Value3 := If(Range<>0,Volume/Range,0);

ma(Value1,100,S);

[linestyle=Grounded Bar; width=4]

[Color=Cyan] { Normal bars }

Volume;

[Color=Gold] { Low volume bars }

If(Value1 = Lowest(Value1,20),V,undefined);

[Color=Red] { Volume climax bars }

If(Value2 = Highest(Value2,20),V,undefined);

[Color=Lime Green] { High churn bars }

If(Value3 = Highest(Value3,20),V,undefined);

[Color=Magenta] { Climax & High churn bars }

If(Value2 = Highest(Value2,20) and Value3 = Highest(Value3,20),V,undefined);

[Color=Coral] { Low churn bars }

If(Value3 = Lowest(Value3,20),V,undefined)

 



Posted By: Tanaka
Date Posted: 22 Mar 2011 at 8:38pm

Maximo! You are starting to make me feel guilty for not knowing how to code.  You are to my rescue once again, and I’m very grateful. If you’re ever down Geelong way I owe you some beers!

The indicator is wonderful as usual! Thumbs Up

Tanaka



Posted By: Niftyg
Date Posted: 23 Mar 2011 at 1:29pm
Hi Max,
 
Firstly I would just like to thank you for sharing your expertise and BullCharts coding. I have been a bullcharts user for a number of years now and look at this forum frequently to see if you have posted.  I'm afraid coding has me mostly beat.
 
I have looked at this indicator you have kindly provided/re-coded and I think it may assist me in my trading.
 
Having looked at the web site noted in the indicator, I was wondering if you could please add in that the volume climax up bar (colour red) should only appear on a bar when the close is higher than the open and the volume climax down bar (colour gold) should only appear when the close is lower than the open. This would then I think better reflect the indicator described on the web site.
 
Many thanks
 
 


Posted By: Tanaka
Date Posted: 23 Mar 2011 at 1:41pm
Originally posted by maximo

That appears to be only part of the indicator for tick bars, coloured Cyan.
 
Here is the full Better Volume Indicator from their site, recoded in Bullscript.
 
Enjoy!

 


Sorry to disturb you again Maximo, I was trying to use this indictor to scan, but it can't produce any signals. Can this be done?



Posted By: Tanaka
Date Posted: 23 Mar 2011 at 1:49pm
Originally posted by Niftyg


Having looked at the web site noted in the indicator, I was wondering if you could please add in that the volume climax up bar (colour red) should only appear on a bar when the close is higher than the open and the volume climax down bar (colour gold) should only appear when the close is lower than the open. This would then I think better reflect the indicator described on the web site.
 

You're right Niftyg. Good picking up on that! Clap


Posted By: maximo
Date Posted: 23 Mar 2011 at 7:49pm
Good work Nifty, those changes made appear to be better signals.
 
Tanaka, the colours need to be assigned to variables for a scan to
pick them up.  Should be okay now.
 
Good trading guys!
 
 

[description="Better Volume Indicator - http://emini-watch.com/free-stuff/volume-indicator/"]

Range := High - Low;

Value1 := Volume;

Value2 := Volume*Range;

Value3 := If(Range<>0,Volume/Range,0);

ma(Value1,100,S);

[linestyle=Grounded Bar; width=4]

[Color=Cyan] { Normal bars }

Volume;

[Color=Gold] { High volume bars }

GoldBar:=If(Value1 = Highest(Value1,20) and Close > Open,V,undefined);

GoldBar;

[Color=Red] { Volume climax bars }

RedBar:=If(Value2 = Highest(Value2,20) and Close < Open,V,undefined);

RedBar;

[Color=Lime Green] { High churn bars }

GreenBar:=If(Value3 = Highest(Value3,20),V,undefined);

GreenBar;

[Color=Magenta] { Climax & High churn bars }

MagentaBar:=If(Value2 = Highest(Value2,20) and Value3 = Highest(Value3,20),V,undefined);

MagentaBar;

[Color=Coral] { Low churn bars }

OrangeBar:=If(Value3 = Lowest(Value3,20),V,undefined);

OrangeBar;

 


Posted By: Niftyg
Date Posted: 24 Mar 2011 at 10:11am
Hi Max and Tanaka,
 
Thanks for the re-coding Max Clap, however one small correction needs to be made. You just need to switch the < and > around for the red and gold bars. The red bar, the Close < Open, should read close > open and the gold bar should be Close < Open.
 
I have already changed it on my indicator (I can manage minor editing), just wanted to bring it to your and other readers attention.
 
Thanks Tanaka for bringing the indicator to my notice.Big smile


Posted By: Tanaka
Date Posted: 24 Mar 2011 at 11:57am
Originally posted by Niftyg

Hi Max and Tanaka,
 
Thanks for the re-coding Max Clap, however one small correction needs to be made. You just need to switch the < and > around for the red and gold bars. The red bar, the Close < Open, should read close > open and the gold bar should be Close < Open.
 
I have already changed it on my indicator (I can manage minor editing), just wanted to bring it to your and other readers attention.
 
Thanks Tanaka for bringing the indicator to my notice.Big smile


Right once again Niftyg! I have made the changes. Once again thank you Max for your coding and thank you Niftyg for your diligence.

I have already found the indicator quickens up my analysis of volume/price action. I think I might even play around with the standard 20 bar look back to see if there are more optimal settings even though at first glance 20 bars looks sufficient.

I don’t want to bother Max anymore, he has been too kind! so does anyone know what I am doing wrong? I just want to set up my scan so that it finds EOD results from this indicator, when I put the first value to compare in BullScans as Better Volume Indicator (result 3) is true, I get an error message ‘The condition type you have selected may not be used with the type of first value’.

Happy trading everyone! Smile




Posted By: Niftyg
Date Posted: 24 Mar 2011 at 12:49pm
Hi Tanaka,
 
I think I might be able to answer that for you. Try using "is defined" instead of true.
 
Regards
 
Nifty


Posted By: Niftyg
Date Posted: 24 Mar 2011 at 1:34pm
Hi Max and Tanaka,
 
Just a further update.
 
Change the coding of the orange bar to:

If(Value1 = Lowest(Value1,20),V,undefined);

if you want to see the lowest volume bar in the last 20 bars as per the web site.
 
Regards
 
Nifty


Posted By: maximo
Date Posted: 24 Mar 2011 at 3:17pm
Yes that looks more consistent Nifty!
 
{ Updated code}
 
[description="Better Volume Indicator - http://emini-watch.com/free-stuff/volume-indicator/ - http://emini-watch.com/free-stuff/volume-indicator/ "]
Range := High - Low;
Value1 := Volume;
Value2 := Volume*Range;
Value3 := If(Range<>0,Volume/Range,0);
ma(Value1,100,S);
[linestyle=Grounded Bar; width=4]
[Color=Cyan] { Normal bars }
Volume;
[Color=Gold] { High volume bars }
GoldBar:=If(Value1 = Highest(Value1,20) and Close < Open,V,undefined);
GoldBar;
[Color=Red] { Volume climax bars }
RedBar:=If(Value2 = Highest(Value2,20) and Close > Open,V,undefined);
RedBar;
[Color=Lime Green] { High churn bars }
GreenBar:=If(Value3 = Highest(Value3,20),V,undefined);
GreenBar;
[Color=Magenta] { Climax & High churn bars }
MagentaBar:=If(Value2 = Highest(Value2,20) and Value3 = Highest(Value3,20),V,undefined);
MagentaBar;
[Color=Coral] { Low churn bars }
OrangeBar:=If(Value1 = Lowest(Value1,20),V,undefined);
OrangeBar;


Posted By: cudderbean
Date Posted: 24 Mar 2011 at 4:30pm
Hear hear, Tanaka!
 
Thank you Maximo and Niftyg for your very generous sharing of ideas... your coding really helps newbies like me  to learn.
 
Have you considered an e-manual to supplement the Bullscript and Bullscan help files. I'd certainly buy it.
 
i think BC already beats Metastock hands down.. mainly because of the ease of importing and exporting lists to Excel and into WebIress for instance.
 
Such a manual might boost user numbers.. the more the merrier.
 
Thanks once more.
 


-------------


Posted By: holygrail
Date Posted: 06 Jul 2018 at 9:15am
Hello, hoping Maximo or Niftyg (or anyone still following this thread) are able to help here.
I believe the Better Volume Indicator has been updated since Maximos last post of 2011. Is it possible for one of the coding gurus to visit http://emini-watch.com/free-stuff/volume-indicator/ and see if they can reproduce the new version for BullCharts?
I tried but failed miserably :(
Thank you in advance.




Print Page | Close Window

Bulletin Board Software by Web Wiz Forums® version 9.69 - http://www.webwizforums.com
Copyright ©2001-2010 Web Wiz - http://www.webwiz.co.uk