home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Monster Media 1993 #2
/
Image.iso
/
finance
/
tas515dm.zip
/
EXAMPLES.ZIP
/
VIDYA.TAS
< prev
next >
Wrap
Text File
|
1992-11-29
|
896b
|
37 lines
{ This script plots a VIDYA graph in the top window.
The bottom window shows the short and long modulation
for the moving avg.
}
#MAX_QUOTES 350
period = 21;
period2 = 34;
period3 = 55;
div_stdm : array;
div_stdm = div(std(c,period),std(c,period2));
vidyam : array;
vidyam = mov(c,
int(mulby(
div_stdm,period2)),
'e');
div_stdl : array;
div_stdl = div(std(c,period2),std(c,period3));
vidyal : array;
vidyal = mov(c,
int(mulby(
div_stdl,period3)),
'e');
{ if over(vidyam,vidyal)<0 then }
gosub dograph;
return
:dograph
opengraph(2,-256,0);
sizegraph(1,1);
graph(1,'price',
mov(c,period2,'e'),'day EMA',
vidyam,'VIDYAM ',
vidyal,'VIDYAL ');
graph(div_stdm,'div_stdm ',
div_stdl,'div_stdl');
closegraph();
return;