Closed
Description
Description
Call getSymbols("7203.T", src="yahooj")
is raised XML error.
I tried use debug
function.
debug(getSymbols.yahooj)
...
debug: URL <- paste(yahoo.URL, "?code=", Symbols.name, "&sm=", from.m,
"&sd=", sprintf("%.2d", from.d), "&sy=", from.y, "&em=",
to.m, "&ed=", sprintf("%.2d", to.d), "&ey=", to.y, "&tm=d",
"&p=", page, sep = "")
Browse[3]> n
debug: fdoc <- XML::htmlParse(URL)
Browse[3]> URL
[1] "https://info.finance.yahoo.co.jp/history/?code=7203.T&sm=1&sd=01&sy=2007&em=7&ed=11&ey=2020&tm=d&p=1"
Browse[3]> fdoc <- XML::htmlParse(URL)
Error: XML content does not seem to be XML: '1'
step through the execution of a function is
Line 501 in c9777da
Next, open URL https://info.finance.yahoo.co.jp/history/?code=7203.T&sm=1&sd=01&sy=2007&em=7&ed=11&ey=2020&tm=d&p=1 is displayed stock price of TOYOTA.
Expected behavior
Get stock price of TOYOTA.
Minimal, reproducible example
> getSymbols("7203.T", src="yahooj")
Error in getSymbols.yahooj(Symbols = "7203.T", env = <environment>, verbose = FALSE, :
Unable to import “7203.T”.
XML content does not seem to be XML: '1'
Session Info
R version 4.0.0 (2020-04-24)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 16.04.6 LTS
Matrix products: default
BLAS: /usr/lib/atlas-base/atlas/libblas.so.3.0
LAPACK: /usr/lib/atlas-base/atlas/liblapack.so.3.0
locale:
[1] LC_CTYPE=C.UTF-8 LC_NUMERIC=C
[3] LC_TIME=C.UTF-8 LC_COLLATE=C.UTF-8
[5] LC_MONETARY=C.UTF-8 LC_MESSAGES=C.UTF-8
[7] LC_PAPER=C.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] LC_MEASUREMENT=C.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets
[6] methods base
other attached packages:
[1] XML_3.99-0.4 quantmod_0.4.17 TTR_0.23-6
[4] xts_0.12-0 zoo_1.8-8
loaded via a namespace (and not attached):
[1] compiler_4.0.0 tools_4.0.0 curl_4.3
[4] grid_4.0.0 lattice_0.20-41
Metadata
Assignees
Labels
No labels