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

Re: Warning about accuracy of Array functions in TS2000i



PureBytes Links

Trading Reference Links

To drive the point home, I made a system from Bob Fulks' test code for
the average function. This is the kind of coding that any TS user unaware
of the single precision problem might do. Obviously this particular
system should never trade because Ave1 should always equal Ave2.

----------
Input: Length(4);

Vars: Price(Close), Ave1(Close), Ave2(Close);

Ave1 = Average(Close, Length);
Price = Close;
Ave2 = Average(Price, Length);

If Ave1 > Ave2 then buy;
If Ave1 < Ave2 then sell;
--------------

I applied the system to INDU with BigPointValue set to 10 to simulate
the futures. As you can see below, you ignore single precision at your
own risk.

------------
test  INDU-Daily   01/05/1970 - 03/17/2000			 

	Performance Summary:  All Trades		 

Total net profit	$ -21689.59	Open position P/L	$  -1986.20
Gross profit    	$  52508.70	Gross loss      	$ -74198.30

Total # of trades	      30	Percent profitable	      50%
Number winning trades	      15	Number losing trades	      15

Largest winning trade	$  17185.70	Largest losing trade	$ -35388.70
Average winning trade	$   3500.58	Average losing trade	$  -4946.55
Ratio avg win/avg loss	       0.71	Avg trade(win & loss)	$   -722.99

Max consec. winners	       6	Max consec. losers	       3
Avg # bars in winners	      93	Avg # bars in losers	     405

Max intraday drawdown	$-141925.80		 
Profit factor   	       0.71	Max # contracts held	       1
Account size required	$ 141925.80	Return on account	     -15%

-- 
  Dennis