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

Re: Indicator



PureBytes Links

Trading Reference Links


> > and, allow the time frame to be
> > varied so that it would be whatever number of days (time periods /
> > bars) from the start date (period).


ok, here is the code:

you can INPUT the date at: WHEN(981111)

you can INPUT the numbers of days to extend the line at date at: 
HOWlong(30)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
vars: quarter(0),ID_bar(0);
input: WHEN(981111),HOWlong(30),UPPER(10),LOWER(-10);

if date = WHEN then begin
	 quarter = c[1];
	 ID_bar = BARNUMBER;
end;

if quarter <> 0 and BARNUMBER <= ID_BAR +HOWlong then begin

plot1(quarter,"quarter");
plot2(plot1 * (1 + (UPPER/100)),"upper");
plot3(plot1 * (1 + (LOWER/100)),"lower");

end;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

this will count the BARNUMBERS, i.e. the number of TRADING days,

rgds hans