[R-SIG-Finance] quantstrat maCross demo problem

hifin hifin at live.com
Thu Jul 12 05:04:56 CEST 2012


The demo code specifies that the strategy enters and exits on the long side.
How come it also enters on the short side. Is this a bug? 

stratMACROSS <- add.rule(strategy = stratMACROSS,name='ruleSignal',
arguments = list(sigcol="ma50.gt.ma200",sigval=TRUE, orderqty=100,
ordertype='market', orderside='long'),type='enter')

stratMACROSS <- add.rule(strategy = stratMACROSS,name='ruleSignal',
arguments = list(sigcol="ma50.lt.ma200",sigval=TRUE, orderqty=-100,
ordertype='market', orderside='long'),type='exit')



--
View this message in context: http://r.789695.n4.nabble.com/quantstrat-maCross-demo-problem-tp4636089p4636249.html
Sent from the Rmetrics mailing list archive at Nabble.com.



More information about the R-SIG-Finance mailing list