0

I am trying to retrieve the SP500 data with:

SP500 <- getSymbolsundefined"^GSPC", from ="2000-01-01", to = "2016-08-31", auto.assign = FALSE)

But I got the following error:

Error: unexpected string constant in "SP500 <- getSymbolsundefined"^GSPC""

Any advice?

demonplus
  • 5,613
  • 12
  • 49
  • 68
José
  • 189
  • 7

1 Answers1

0

Um, you have a trivial syntax error? This obviously works:

SP500 <- getSymbols("^GSPC", from ="2000-01-01", to = "2016-08-31", auto.assign = FALSE)

FXQuantTrader
  • 6,821
  • 3
  • 36
  • 67