[R-SIG-Finance] Strange results from Quantstrat

이원재 wjlee2002 at naver.com
Sat Dec 24 12:34:21 CET 2011


Hi, all
This is a simply intra-day system which goes short in the morning and exits in the afternoon.
If the test data has '1' in the column of 'isShort_entrySymbol, it goes short, and if the test data has '1' in the column of 'isexitShort', it exits. 
In this case, the data is just from 2006-01-11 to 2006-01-13, and it has the value '1' in those columns in 2006-01-12.
I ran the system with quantstrat package, but there was not trades at all.
> tradeStats("test")[,c("Symbol","Num.Trades","Net.Trading.PL","maxDrawdown")]
NULL
But When I ran the system for only 2006-01-12 data (I commented out the line in the attached source), I got 41 trades like below
> tradeStats("test")[,c("Symbol","Num.Trades","Net.Trading.PL","maxDrawdown")]
 Symbol Num.Trades Net.Trading.PL maxDrawdown 
testSymbol 41 -1.2 -24 
Please tell me what's wrong with the system.
Thanks.
Wonjae Lee
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://stat.ethz.ch/pipermail/r-sig-finance/attachments/20111224/eddce7de/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: intra-day.system.R
Type: application/octet-stream
Size: 1888 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-finance/attachments/20111224/eddce7de/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: testSymbol.csv
Type: text/comma-separated-values
Size: 38220 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-finance/attachments/20111224/eddce7de/attachment.bin>


More information about the R-SIG-Finance mailing list