[amibroker] Backtest Periodicity Weekly [newbie question!]

 

I have, up to now, been doing backtests on a "daily" periodicity. Buy/sell on next bar open.


I am now looking at a backtest using "weekly" periodicity. Running it today [28th] using trade data to last Friday [26th] I am getting trades showing as 6 March but using the close for the 22 February


Another Symbol that opened a trade on 26 February used the open price for 22 February.


This is a sample AFL that I have used. I have also used other backtests and get the same outcomes


SetOption("InitialEquity",50000);
SetOption("MaxOpenPositions",10);
SetPositionSize(10,spsPercentOfEquity);
SetTradeDelays( 1, 1, 1, 1 );

// buy & sell conditions


In settings I have periodicity set to Weekly.


What I am aiming is to run the backtest each weekend with data updated for the Friday. I would anticipate new trades being set for the following Monday at the open price.


It doesn't seem that hard, but it is not working.

Any advice on what I am not doing or misunderstanding will be appreciated!

Thanks

__._,_.___

Posted by: tonyjw11@yahoo.com.au
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)
**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/


.

__,_._,___


EmoticonEmoticon