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

Re: [amibroker] Optimizing a system on an Index



PureBytes Links

Trading Reference Links

Hi,

Indices are just another ticker, they shouldn't be treated any differently 
by AB. Two thoughts come to mind:

1. In TC2K, the ticker for SPX is "SP-500". Is that what you are using?

2. Since an index is probably less volatile than most stocks, is it possible 
that there really aren't any crossovers during the period you are testing?

Also, you could probably remove the Exrem statements, since you shouldn't 
have redundant signals on a MA crossover/reversal system. (ie - cant cross 
twice in the same direction w/o crossing back first)

Steve

----- Original Message ----- 
From: "eman197" <kb1fuo@xxxxxxxxxxxx>
To: <amibroker@xxxxxxxxxxxxxxx>
Sent: Saturday, October 22, 2005 9:17 AM
Subject: [amibroker] Optimizing a system on an Index


> Sorry to bother the group with what I'm sure is an easy question.  I
> would like to optimize a trading system (for example the simple MA
> crossover below) on an Index such as SPX.
>
> When I run Optimize, it does not find any trades. However, when I use
> a stock symbol, such as IBM, Optimize works correctly.
>
> I am using data from TC2000 and have tried data from MSNMoney and it
> does not work.  It seems that Index data is handled differently than
> normal stock data when running Optimize or Backtest.
>
> I'd appreciate any help.
>
> eman
>
>
>
> fast=10;
> slow=41;
> fast=Optimize("fast",2,2,20,1);
> slow=Optimize("slow",7,20,42,1);
>
> Buy=Ref(EMA(C,fast),-1) < Ref(EMA(C,slow), -1) AND EMA(C,fast) >
> EMA(C,slow);
> Sell=Ref(EMA(C,fast),-1) > Ref(EMA(C,slow), -1) AND EMA(C,fast) <
> EMA(C,slow);
> Short=Ref(EMA(C,fast),-1) > Ref(EMA(C,slow), -1) AND EMA(C,fast) <
> EMA(C,slow);
> Cover=Ref(EMA(C,fast),-1) < Ref(EMA(C,slow), -1) AND EMA(C,fast) >
> EMA(C,slow);
>
>
> Filter=Buy OR Sell OR Short OR Cover;
> Buy=ExRem(Buy,Sell); Sell=ExRem(Sell,Buy); Short=ExRem(Short,Cover);
> Cover=ExRem(Cover,Short);
>
> AddColumn(Buy,"Buy");
> AddColumn(Sell,"sell");
> AddColumn(Short,"short");
> AddColumn(Cover,"cover");
> AddColumn(Open,"
>
>
>
>
>
>
>
>
> Please note that this group is for discussion between users only.
>
> To get support from AmiBroker please send an e-mail directly to
> SUPPORT {at} amibroker.com
>
> For other support material please check also:
> http://www.amibroker.com/support.html
>
>
> Yahoo! Groups Links
>
>
>
>
>
>
> 




------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.html

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/amibroker/

<*> To unsubscribe from this group, send an email to:
    amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/