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

RE: [amibroker] Tranformations



PureBytes Links

Trading Reference Links


<SPAN 
class=100250513-29072002>Dimitris:  still another creative application of 
variables and code!!  I have played with it and find it curious that my 
results differ quite a bit but the trades are all within several days of each 
other. I one case, my system took three (losing trades) that your system did not 
have.  I do not wish to go thru each trade to find that the data we have is 
different---which has to be the case.  My TC2000 data must differ just 
slightly to cause such small differences in buy and sell 
dates.
<SPAN 
class=100250513-29072002> 
I 
guess I have never been concerned before about data accuracy and assumed that 
TC2k was ok. AB gives us, however, the chance to see some differences in 
backtest results caused by slight differences in data and makes us wonder where 
the highest quality data source really is.
<SPAN 
class=100250513-29072002> 
BTW, 
my INTC result with transformation was +91%, without it +27%.  Pretty big 
differences but in no way detracts from the beauty of your 
code.
<SPAN 
class=100250513-29072002> 
Ken 

<FONT face=Tahoma 
size=2>-----Original Message-----From: Dimitris Tsokakis 
[mailto:TSOKAKIS@xxxx]Sent: Monday, July 29, 2002 5:41 
AMTo: amibroker@xxxxxxxxxxxxxxxSubject: [amibroker] 
Tranformations
Suppose you trade INTC with a Stochastic CCI [6,12,70] 
system.The total % net profit, after 18trades/12 winners/6losers is 
-15.85%See INTC1.gif[buy,sell,short,cover at open, delay +1, commission 
0.5%, all stops disabled] with the use of the code:
 
/*Smoothed Stochastic CCI*/P 
=6;D=DateNum()>1000301;Blevel =Optimize("BL",12,10,20,1);Slevel = 
Optimize("SL",70,70,90,1);StOcci=100*(CCI(6)-LLV(CCI(6),14))/(HHV(CCI(6),14)-LLV(CCI(6),14));stocci=MA(stocci,5);Buy=Cross(STOCCI,BLEVEL);Sell= 
Cross(STOCCI, Slevel); Buy=D*(Buy);Sell=D*Sell;Short = Sell;Cover= 
Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);E1=Equity();EM40=MA(E1,40);XB=Flip(Buy,Sell);XS=Flip(Sell,Buy);XSH=2*Flip(Short,Cover);XCO=2*Flip(Cover,Short);XBSH=(XB+XSH);XSXCO=(XS+XCO);ASC=Cross(E1,EM40);DESC=Cross(EM40,E1);
// 
Buy=ASC*(XBSH==1);Sell=DESC*(XSXCO==1);Short=ASC*(XBSH==2);Cover=DESC*(XSXCO==2);
 
Do you want to transform the -15.85% to a +126% somehow 
automatically ?Simply delete the // from the last line 
!!6trades/5winners/1loser and that´s it.
See INTC2.gifDimitris TsokakisPS1. Any volunteers to 
improve this method and reach its final form with a co-operative work 
??
We may create a method belonging to this excellent 
list.
This is my ambition. I know what to 
do for myself. With or, sometimes, without strict coding.
PS2. The above combination [6,12,70] is just for the 
example
PS3. Some other examples
CSCO from +39% to +364%
MSFT from -11% to +87%
QQQ from +158% to +328%
but
ORCL from +36% to +9% etc. etc  
 
 Your 
use of Yahoo! Groups is subject to the <A 
href="">Yahoo! Terms of Service.