[Blotter-commits] r57 - pkg/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Tue Mar 3 03:57:04 CET 2009
Author: peter_carl
Date: 2009-03-03 03:57:04 +0100 (Tue, 03 Mar 2009)
New Revision: 57
Modified:
pkg/R/calcAcctAttr.R
Log:
- fixed result transformation into xts object
Modified: pkg/R/calcAcctAttr.R
===================================================================
--- pkg/R/calcAcctAttr.R 2009-01-23 04:44:07 UTC (rev 56)
+++ pkg/R/calcAcctAttr.R 2009-03-03 02:57:04 UTC (rev 57)
@@ -18,7 +18,7 @@
Date = time(Account[[2]][Date])
table = xts(NULL, order.by=Date) ## Reference time index
table = getByPortf(Account, Attribute, Date)
- result = as.xts(t(t(apply(table, FUN='sum', MARGIN=1))))
+ result = xts(apply(table, FUN='sum', MARGIN=1), Date)
colnames(result) = Attribute
return(result)
}
More information about the Blotter-commits
mailing list