[Blotter-commits] r1050 - pkg/quantstrat/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Fri Jun 15 14:48:56 CEST 2012


Author: opentrades
Date: 2012-06-15 14:48:56 +0200 (Fri, 15 Jun 2012)
New Revision: 1050

Modified:
   pkg/quantstrat/R/ruleOrderProc.R
Log:
now treating 'daily' trades like intraday again, ie. obtain price from next bar. weekly and less frequent still use same bar



Modified: pkg/quantstrat/R/ruleOrderProc.R
===================================================================
--- pkg/quantstrat/R/ruleOrderProc.R	2012-06-15 12:46:19 UTC (rev 1049)
+++ pkg/quantstrat/R/ruleOrderProc.R	2012-06-15 12:48:56 UTC (rev 1050)
@@ -101,8 +101,7 @@
                         switch(freq$scale,
                                 yearly = ,
                                 quarterly = ,
-                                monthly = ,
-                                daily = {
+                                monthly = {
                                     txntime=as.character(index(ordersubset[ii,])) # transacts on this bar, e.g. in the intraday cross, or leading into the end of month, quarter, etc.
                                     # txntime=as.character(timestamp) # use this if you wanted to transact on the close of the next bar
                                     txnprice=as.numeric(getPrice(last(mktdata[txntime]), prefer=prefer)[,1])



More information about the Blotter-commits mailing list