添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
相关文章推荐
高大的机器人  ·  Issues with ...·  9 月前    · 
打篮球的作业本  ·  Laravel sync() ...·  10 月前    · 
小眼睛的充值卡  ·  马力的博客·  1 年前    · 

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").