
02-27-2008, 11:58 PM
|
|
Registered Trader
|
|
Join Date: Feb 2007
Posts: 154
Thanks: 50
Thanked 34 Times in 17 Posts
|
|
|
Re: How to Access Higher Timeframe Data
Try this Volume Avg indicator modified for RS. Adjust the input for AvgLength to longer periods e.g. 20 days x 390min /5 on 5 min charts; 390min is 6.5 hrs Reg Trade Hrs.
 |
|
 |
 |
|
 |
|
inputs:
AvgLength( 30 ),
AlertPct( 50 ),
UpColor( Green ),
DownColor( Red ) ;
variables:
VVol( 0 ),
AvgVVol( 0 ),
TVol( 0 ),
AvgTVol( 0 ),
AlertFactor( 1 + AlertPct * .01 ),
AlertStr( NumToStr( AlertPct, 2 ) ) ;
if BarType >= 2 then { ie, not tick/minute data }
begin
VVol = Volume ;
AvgVVol = AverageFC( Volume, AvgLength ) ;
Plot1( VVol, "Vol" ) ;
Plot2( AvgVVol, "VolAvg" ) ;
{ Alert criteria }
if VVol crosses over AvgVVol * AlertFactor then
Alert( "Volume breaking through " + AlertStr + "% above its avg" ) ;
end
else { if tick/minute data; in the case of minute data, also set the "For volume,
use:" field in the Format Symbol dialog to Trade Vol or Tick Count, as desired }
begin
TVol = Ticks ;
AvgTVol = AverageFC( Ticks, AvgLength ) ;
Plot1( TVol, "Vol" ) ;
Plot2( AvgTVol, "VolAvg" ) ;
{ Alert criteria }
if TVol crosses over AvgTVol * AlertFactor then
Alert( "Volume breaking through " + AlertStr + "% above its avg" ) ;
end ;
{ Color criteria }
if UpTicks > DownTicks then
SetPlotColor( 1, UpColor )
else if UpTicks < DownTicks then
SetPlotColor( 1, DownColor ) ; |
|
 |
|
 |
|
|