[Blotter-commits] r553 - pkg/blotter/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Feb 10 21:42:58 CET 2011


Author: braverock
Date: 2011-02-10 21:42:58 +0100 (Thu, 10 Feb 2011)
New Revision: 553

Modified:
   pkg/blotter/R/getPosAvgCost.R
Log:
- update getPosAvgCost to use new columns functionality in getPos

Modified: pkg/blotter/R/getPosAvgCost.R
===================================================================
--- pkg/blotter/R/getPosAvgCost.R	2011-02-10 20:37:53 UTC (rev 552)
+++ pkg/blotter/R/getPosAvgCost.R	2011-02-10 20:42:58 UTC (rev 553)
@@ -9,7 +9,7 @@
 { # @author Peter Carl
     pname<-Portfolio
     # FUNCTION
-    PosAvgCost = as.numeric(getPos(pname, Symbol, Date)[,"Pos.Avg.Cost"])
+    PosAvgCost = as.numeric(getPos(pname, Symbol, Date, Columns='Pos.Avg.Cost'))
     return(PosAvgCost)
 }
 



More information about the Blotter-commits mailing list