[Blotter-commits] r1133 - pkg/blotter/R
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sun Aug 26 01:16:53 CEST 2012
Author: gsee
Date: 2012-08-26 01:16:52 +0200 (Sun, 26 Aug 2012)
New Revision: 1133
Modified:
pkg/blotter/R/updatePortf.R
Log:
subset xts instead of list containing xts. Thanks to Generalenthu from SO for the bug report.
Modified: pkg/blotter/R/updatePortf.R
===================================================================
--- pkg/blotter/R/updatePortf.R 2012-08-25 08:42:47 UTC (rev 1132)
+++ pkg/blotter/R/updatePortf.R 2012-08-25 23:16:52 UTC (rev 1133)
@@ -75,7 +75,7 @@
else {summary=cbind(summary,result)}
}
- if(!is.timeBased(Dates)) Dates = xts:::time.xts(Portfolio$symbols[[1]][Dates])
+ if(!is.timeBased(Dates)) Dates = xts:::time.xts(Portfolio$symbols[[1]][["posPL"]][Dates])
startDate = first(xts:::.parseISO8601(Dates))$first.time-.00001
# trim summary slot to not double count, related to bug 831 on R-Forge, and rbind new summary
if( as.POSIXct(attr(Portfolio,'initDate'))>=startDate || length(Portfolio$summary)==0 ){
More information about the Blotter-commits
mailing list