[Blotter-commits] r64 - pkg/demo

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Fri Mar 6 17:44:49 CET 2009


Author: peter_carl
Date: 2009-03-06 17:44:48 +0100 (Fri, 06 Mar 2009)
New Revision: 64

Modified:
   pkg/demo/turtles.R
Log:
- changed final chart theme to make trades easier to see


Modified: pkg/demo/turtles.R
===================================================================
--- pkg/demo/turtles.R	2009-03-06 16:06:01 UTC (rev 63)
+++ pkg/demo/turtles.R	2009-03-06 16:44:48 UTC (rev 64)
@@ -160,7 +160,7 @@
   Sells = portfolio[["XLF"]]$txn$Txn.Price*(portfolio[["XLF"]]$txn[,'Txn.Qty']<0)
   Position = portfolio[["XLF"]]$posPL[,'Pos.Qty']
   CumPL = cumsum(portfolio[["XLF"]]$posPL[,'Trading.PL'])
-  chartSeries(XLF['2008::2009',], TA=NULL, type='bar')
+  chartSeries(XLF['2008::2009',], TA=NULL, type='bar', theme=chartTheme('white',up.col='lightgreen',dn.col='pink'))
   plot(addTA(Buys['2008::2009',],pch=2,type='p',col='darkgreen', on=1));
   plot(addTA(Sells['2008::2009',],pch=6,type='p',col='darkred', on=1));
   plot(addTA(Position['2008::2009',],type='h',col='blue', lwd=2));



More information about the Blotter-commits mailing list