Saturday, June 17, 2017

get.hist.quote not working and the fix

The get.hist.quote command of tseries package was not working. But it has been fixed, however, the argument has changed slightly.

Here is the quick fix. Install the latest tseries package and load the package in the enviroment.

install.packages("tseries")
library("tseries")

To perform the GARCH model as in my previous blog (here). Instead of using the code (as in that blog)

DJI.data = get.hist.quote(instrument="^DJI", start="2010-01-01", end="2015-07-23", quote="AdjClose", provider="yahoo", compression="d", retclass="zoo")

Use the following.

DJI.data = get.hist.quote(instrument="^DJI", start="2010-01-01", end="2015-07-23", quote="Adjusted", provider="yahoo", compression="d", retclass="zoo")

plot(DJI.data)

Here is the video with explanation.



2 comments:

  1. Error Correction Model (ECM) Panel Data EVIEWS 9
    https://www.youtube.com/watch?v=ZgCwrb6kI7w
    video Introduce the concept of an Error Correction Model (ECM) Panel Data EVIEWS 9.
    WhatsApp : +6285227746673
    PIN BB : D04EBECB
    IG : @olahdatasemarang

    ReplyDelete
  2. can u share codes & material for SARIMAX ,

    ReplyDelete