PureBytes Links
Trading Reference Links
|
The optimization
// Nikkei 2003 timing
OptimizationSYM="^N225";STARTBUY=DateNum()==1030131;STARTSELL=DateNum()==1030217;BuyFREQ=Optimize("bf",10,10,40,1);SellFREQ=Optimize("sf",10,10,40,1);Buy=BarsSince(STARTBuy)%Buyfreq
==0;Sell=BarsSince(STARTSell)%Sellfreq==0;Short=Sell;Cover=Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);gives
the top4 combinations25/28, 18/37, 33/28, 16/28.
The graph
// Nikkei 2003 timing
GraphSYM="^N225";STARTBUY=DateNum()==1030131;STARTSELL=DateNum()==1030217;BuyFREQ=25;SellFREQ=28;Buy=BarsSince(STARTBuy)%Buyfreq
==0;Sell=BarsSince(STARTSell)%Sellfreq==0;Short=Sell;Cover=Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);Plot(Equity(),WriteVal(BuyFREQ,1.0)+"/"+WriteVal(SellFREQ,1.0),1,1);BuyFREQ=18;SellFREQ=37;Buy=BarsSince(STARTBuy)%Buyfreq
==0;Sell=BarsSince(STARTSell)%Sellfreq==0;Short=Sell;Cover=Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);Plot(Equity(),WriteVal(BuyFREQ,1.0)+"/"+WriteVal(SellFREQ,1.0),2,1);BuyFREQ=33;SellFREQ=28;Buy=BarsSince(STARTBuy)%Buyfreq
==0;Sell=BarsSince(STARTSell)%Sellfreq==0;Short=Sell;Cover=Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);Plot(Equity(),WriteVal(BuyFREQ,1.0)+"/"+WriteVal(SellFREQ,1.0),4,1);BuyFREQ=16;SellFREQ=28;Buy=BarsSince(STARTBuy)%Buyfreq
==0;Sell=BarsSince(STARTSell)%Sellfreq==0;Short=Sell;Cover=Buy;Buy=ExRem(Buy,Sell);Sell=ExRem(Sell,Buy);Short=ExRem(Short,Cover);Cover=ExRem(Cover,Short);Plot(Equity(),WriteVal(BuyFREQ,1.0)+"/"+WriteVal(SellFREQ,1.0),5,1);
gives more details.The future is, as usual,
unknown.Dimitris Tsokakis
Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.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 the Yahoo! Terms of Service.
Attachment:
4opt.gif
Attachment:
Description: "Description: GIF image"
|