Skip to content

Constant (= wrong) historical quotes via get.hist.quote() from yahoo.finance

3 messages · Achim Zeileis, Marius Hofert

#
Dear expeRts,

I would like to download a time series of historical data from the ticker with symbol "ROG.VX". Interestingly, I obtain constant values (138.3 for each day in the chosen period) although the yahoo.finance website tells me that the time series is not at all constant. What's wrong?

Cheers,

Marius


require(tseries)
hq <- get.hist.quote(instrument="ROG.VX", start="2011-09-09", end="2012-03-28",
                     quote="Close", provider="yahoo", drop=TRUE)
plot(hq) # => constant
stopifnot(hq==138.3) # => constant 138.3
## However, under http://finance.yahoo.com/q/hp?s=ROG.VX&a=08&b=09&c=2011&d=02&e=28&f=2012&g=d&z=66&y=132
## the historical prices are not all equal to 138.3
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20121123/677e6098/attachment.bin>
#
On Fri, 23 Nov 2012, Marius Hofert wrote:

            
Yahoo! Finance.
It's true that that web page displays the prices correctly. However, if 
you click on "Download to Spreadsheet" you also get the constant 138.3 
prices. And the spreadsheet functionality is what get.hist.quote() and 
other R interface to Yahoo! Finance use.

Hence, you either have to process the HTML table or have to hope that 
Yahoo! Finance fixes the problem. Not sure whether they have functionality 
to report such problems...

Best,
Z
#
Dear Achim,

Thanks a lot for your quick help. Indeed, I did not realize that the "Download to
Spreadsheet" gives the wrong result, so it's really a Yahoo! Finance issue (too
bad, an R issue would have been easier to fix :-) ).

Thanks again,

Marius


Achim Zeileis <Achim.Zeileis at uibk.ac.at> writes:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20121123/e54e726e/attachment.bin>