COCO研究院

 找回密碼
 註冊
搜索
123
返回列表 發新帖
樓主: orangelam

[教學] 有關futures position size 一問

[複製鏈接]
發表於 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.



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.

 樓主| 發表於 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.
 樓主| 發表於 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?
您需要登錄後才可以回帖 登錄 | 註冊

本版積分規則

手機版|Archiver|站長信箱|廣告洽詢|COCO研究院

GMT+8, 24-11-23 03:24

Powered by Discuz! X3.4

Copyright © 2001-2023, Tencent Cloud.

快速回復 返回頂部 返回列表
理財討論網站 |