How to adjust historical intraday data? (solved)

Discussion in 'Data Sets and Feeds' started by bellman, Mar 28, 2016.

  1. bellman

    bellman

    Okay, thanks to this thread, I am now scraping the eod closing price and adjusted closing price from yahoo.

    HOWEVER, I have a very important question: Given the closing price and the adjusted closing price, how should I adjust that day's intraday data?

    MSFT data

    Feb 12, 2016 Close = $50.50 Adjusted Close = $50.14

    So, the adjustment for Feb 12, 2016 is -$0.36. To adjust the intraday data, do I just subtract $0.36 from every quote and print?

    (This may seem like the common sense correct answer, but I just want to make absolutely certain, as this is something I am not that familiar with).

    Thank you.
     
  2. bellman

    bellman

    Well, I believe I have answered my own question by looking at the data. I need to MULTIPLY each quote and print by the RATIO of (adjusted close) / close.
     
  3. Metamega

    Metamega

    I've only ever used Yahoo data for a but until I noticed their adjusted data also included dividends. This never made sense to me since the dividends are added to the data I believe on the payment date not the ex date.

    I see the importance for someone wanting dividends in their data but this seems like a bad way to do it since using this in a backtest would skew possible live results.

    Just a heads up.
     
  4. bellman

    bellman

    Thank you very much for the heads up. This is very surprising. I will look into it tomorrow to verify whether or not yahoo is adjusting on the ex date or not. (Surely they are, right?)
     
  5. Metamega

    Metamega

    Never mind. I must've did something wrong way back. They do execute on ex date. I do know that it was a pain for charting as the two options I had were unadjusted for splits which isn't always nice when charting and using the adjusted close with dividend which would throw off support/resistance levels or calculations I was using since the adjusted price never existed.

    Both have their benefits and drawdowns.
     
    bellman likes this.
  6. BigTommy

    BigTommy

    Does anyone know if Yahoo's data already has adjusted volume? It seems like the volume is adjusted, but that doesn't make much sense, since nothing else is (except the close).
     
    bellman likes this.
  7. userque

    userque

    Good question. Google bakes in their adjustments. So maybe we could compare the same stock's volume between Google and Yahoo to get an idea.
     
  8. bellman

    bellman

    Actually, Google's historical data does not include any adjustments.

    And, Yahoo does not adjust their volume (but you can easily calculate this adjustment yourself from the closing adjustment price).

    Compare the 2 data sources for MSFT in December 2014:

    Google: https://www.google.com/finance/hist...Dec+31,+2014&num=30&ei=OoX6VpGaO4SA2AaLz7vwCA

    and Yahoo: http://finance.yahoo.com/q/hp?s=MSFT&a=11&b=1&c=2014&d=11&e=31&f=2014&g=d
     
  9. bellman

    bellman

    Yahoo's volume data is not adjusted (at least not for MSFT December 2014 data).
     
  10. bellman

    bellman

    I'm glad you mentioned this. I will not adjust the quote and print data in my backtesting--instead I will adjust the positions that carry over between days. Thank you for pointing that out.
     
    #10     Mar 29, 2016