[Blotter-commits] r92 - pkg/demo
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Fri Jul 17 05:51:17 CEST 2009
Author: peter_carl
Date: 2009-07-17 05:51:17 +0200 (Fri, 17 Jul 2009)
New Revision: 92
Modified:
pkg/demo/turtles.R
Log:
- fixed getSymbols, which was commented out
Modified: pkg/demo/turtles.R
===================================================================
--- pkg/demo/turtles.R 2009-07-15 02:56:39 UTC (rev 91)
+++ pkg/demo/turtles.R 2009-07-17 03:51:17 UTC (rev 92)
@@ -37,11 +37,11 @@
print("Initializing portfolio and account structure")
# Assemble a small portfolio of three stocks
symbols = c("XLY", "XLP", "XLE", "XLF", "XLV", "XLI", "XLB", "XLK", "XLU")
+
+getSymbols(symbols, from=initDate, source="yahoo")
# getSymbols now defaults (as originally) to "Date" indexing. We can change to use POSIXct here.
# getSymbols(symbols, index.class=c("POSIXt","POSIXct"), from=initDate, source="yahoo")
-# getSymbols(symbols, from=initDate, source="yahoo")
-
# Set up a portfolio object and an account object
portfolio = initPortf(symbols, initDate=initDate)
account = initAcct(portfolios="portfolio", initDate=initDate)
More information about the Blotter-commits
mailing list