joshsmi
發表於 14-7-24 05:07
BTW
// Output Equity at entry column in backtest result list
should be
// Output Equity at exit column in backtest result list
it is a typo.
Anyway you can of course have a open trades row without closing trades. But what sense does it make? It is pretty ridiculous to do that.
http://i.imgur.com/qbn9Lua.png
It makes no sense. Why do you need a list output then just to have open trades output??
And if you keep closed trades loop but comment AddcustomMetric in that very same loop then it simply expects the same addcustommetric line in both loops. If it is not existent in both loops then it does not output that column. It is errornous ridiculous coding in both cases.
Simply change the time range if you just need open trades output.
orangelam
發表於 14-7-24 12:49
hi joshsmi, you are absolutely right. it really makes no sense to separate close and open. Actually, i am new in amibroker and i am trying my best to learn from user guide. may be it is my programming sense that i used to separate things as small pieces as possible, that's why i am freaking out of separating it.
Initially, i just want to use two extra different columns to store the open sides. My though is, if it is two separated for-loop, i can loop it separately and even create two different columns for open side. But, i found that it is not possible and i think it is due to the design of the programming logic that close and open information can only be stored in a single field/column. further, i would ask myself, if we cannot separate it, what's the point of using two looping...
but u are right, no sense in seperating it... thanks joshami, i think i should move to next topic instead of stucking here.
orangelam
發表於 14-7-24 13:00
i have a question about open position. if maximum open position=3, does it mean that in a single time, the maximum open position allowed in different symbols(stocks, fx, future etc) is 3, right? if my portfolio only have a single future, the maximum open position is one, right?
how to make colors in your backtest result list above?