[Blotter-commits] r1296 - pkg/quantstrat/demo

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Dec 13 17:23:16 CET 2012


Author: braverock
Date: 2012-12-13 17:23:15 +0100 (Thu, 13 Dec 2012)
New Revision: 1296

Modified:
   pkg/quantstrat/demo/luxor.3.R
Log:
- add SMA lines to chart

Modified: pkg/quantstrat/demo/luxor.3.R
===================================================================
--- pkg/quantstrat/demo/luxor.3.R	2012-12-13 15:36:59 UTC (rev 1295)
+++ pkg/quantstrat/demo/luxor.3.R	2012-12-13 16:23:15 UTC (rev 1296)
@@ -166,13 +166,15 @@
 ###############################################################################
 
 chart.Posn(p, "GBPUSD")
+add_SMA(n=.slow,col='darkblue',on=1)
+add_SMA(n=.fast,col='lightblue',on=1)
 
-print(getOrderBook(p))
+View(getOrderBook(p))
 
 #txns <- getTxns(p, 'GBPUSD')
 #txns
 ###txns$Net 
 #cat('Net profit:', sum(txns$Net.Txn.Realized.PL), '\n')
 
-tradeStats(p, 'GBPUSD')
+View(tradeStats(p, 'GBPUSD'))
 



More information about the Blotter-commits mailing list