Bug???
I am using QP 2.0 along with the new patch obtained from the web site (7/29/98) not the new one posted of 8/26/98.
I tried to calculate the 200 exponential moving average for the stock AEG based upon data up to today 8/26/98.
When I output the QP 2.0 data via the Metastock output utility to Metastock 6.5 and view it, the 200 EMA is calculated to be 70.5762.
When I view this with Quotes Plus Chart 2.0 with the data window menu option, I get 70.5762.
Now, when I write a scan as so:
Println Symbol, EMovAvg(0,200):8:4 returns 71.2372 Println Symbol, EMovAvg(0,199):8:4 returns 71.2114
First of all, I am getting results nowhere near the QP 2.0 chart dataview value and the Metastock 6.5 EMA value.
Second of all, the documentation is messed up.
From the help documentation:
"
output="myfile";
if EMovAvg(0,9,vol)>EMovAvg(0,21,vol) then println symbol; endif;
In this example, EMovAvg(0,9,vol) returns today's value for a 10-day EMA of the volume; EMovAvg(0,21,vol) returns today's value for a 21-day EMA of the volume. The scan selects issues where the value of the short-term EMA exceeds the value of the long-term EMA."
And by the way:
Println Symbol, MovAvg(0,200):8:4 returns 65.7899 Println Symbol, MovAvg(0,199):8:4 returns 65.9204
which is correct in QP 2.0 Dataview, Metastock 6.5, and on the scans.
Is there a bug in the EMovAvg function?
MrBuzz |