In trading we constantly check to see if volume is confirming price. Rising price accompanied by falling volume is often the signal for an impending reversal. The Volume Trend plots the linear regression of the volume for the user specified last number of bars. The color of line reflects the slope – green for rising and red for falling. The Price Trend is a similar linear regression line. In this case, the line is colored blue if the price and volume are of diverging slopes and white else wise. Both indicators will automatically update with each bar. Also pictured is the revised AutoFibLines script. It is completely functional again and now has the added benefit of working on Forex pairs and other symbols trading down in the decimal range. Also added were a reversal dot indicating at what closing price the AutoFibs will reverse direction and update the fib levels as well as a trend direction arrow indicating in which direction the fibs have been drawn. PS: The ToS Script Editor is happy with cutting and pasting from the web again!
# TS_VolumeTrend # http://www.thinkscripter.com # thinkscripter@gmail.com # Last Update 16 Dec 2009 declare on_volume; declare real_size; input period = 50; plot VolTrend = InertiaAll(volume, period); def volumeSlope = if voltrend>voltrend[1] then 1 else 0; VolTrend.assignValueColor(if voltrend>voltrend[1] then color.green else color.red); VolTrend.setLineWeight(2);
# TS_PriceTrend # http://www.thinkscripter.com # thinkscripter@gmail.com # Last Update 16 Dec 2009 input price = close; input period = 50; def offset = 100; def linearPriceTrend = InertiaAll(close, period); def priceSlope = if linearPriceTrend>linearPriceTrend[1] then 1 else 0; def dist = HighestAll(AbsValue(linearPriceTrend - price)) * (offset / 100.0); def VolTrend = InertiaAll(volume, period); def volumeSlope = if voltrend>voltrend[1] then 1 else 0; plot PriceTrend = if priceSlope==0 then linearPriceTrend-dist else if priceSlope==1 then linearPriceTrend+dist else linearPriceTrend; PriceTrend.assignValueColor(if volumeSlope != priceSlope then color.blue else color.white); PriceTrend.setLineWeight(2);






I just put these two hunting dogs on my favorite game (GOOG) and noticed that GOOG’s in declining daily volume! Oh no! : ) The end is nigh!
I have to say, this whole “rally” we’ve been in for nine months just never … never … adds up.
I like this indicator … simple and effective. Will try it out to see how it works. Thanks for making this available.
I pasted into TOS and the two words after the def statement are red highlighted, not sure why, don’t see any odd characters, etc.?
def VolTrend = InertiaAll(volume, period);
def volumeSlope = if voltrend>voltrend[1] then 1 else 0;
Excuse me, duh, sorry, ignore post.
I get the period in red on : input period = 50 and the VolTrend & volumeSlope on the def of same in red
Remove the “declare fullrange;” line as that command has been removed from TOS.
-Eric