How do I solve this problem that I present with the FinCal Package:
get.ohlc.yahoo(symbol="AAPL",start="2013-07-01",end="2013-08-01",freq="w")
Error in file(file, "rt") : cannot open the connection
In addition: Warning message:
In file(file, "rt") :
InternetOpenUrl failed: 'The server name or address could not be resolved'
And I'm browsing Google without problems, in fact I managed to enter the Forum
FinCal
package hasn't been updated several years ago so there is a good chance that the underlying APIs have changed and the package is not going to work anymore, I would recommend you to use a different package like quantmod
library(quantmod)
getSymbols("AAPL", from="2013-07-01", to="2013-08-01", src = "yahoo")
###examole
dat <-getSymbols("AAPL", from="2013-07-01", to="2013-08-01", src = "yahoo")
Warning message:
'indexClass<-' is deprecated.
Use 'tclass<-' instead.
See help("Deprecated") and help("xts-deprecated").
######example 2
getSymbols("AAPL")
[1] "AAPL"
Warning message:
'indexClass<-' is deprecated.
Use 'tclass<-' instead.
See help("Deprecated") and help("xts-deprecated").
##########example3
start_date <- as.Date("2017-01-02")
end_date <- as.Date("2018-02-09")
getSymbols("NYA", src = "yahoo", from = start_date, to = end_date)
[1] "NYA"
Warning message:
'indexClass<-' is deprecated.
Use 'tclass<-' instead.
See help("Deprecated") and help("xts-deprecated").