How to Download Historical Stock Data from Google Into Matlab

April 15, 2009 · Filed Under Stock Market 

Note: Please read the disclaimer. The author is not providing professional investing advice or recommendations.

A while back I posted a Matlab script that downloads historical stock prices from Yahoo Finance using the java interface. Got a couple requests to write one to do the same for Google Finance so here it is.

get_hist_google_stock_data.m

Personally, I prefer Yahoo over Google as they have the extra Adjusted Close column which allows you to normalize for splits, dividends, etc.

But to each his own…


Comments

2 Responses to “How to Download Historical Stock Data from Google Into Matlab”

  1. Rigby on July 15th, 2009 7:00 pm

    I also like yahoo historical data because of the Adjusted Close. However, if you want to download realtime quotes into matlab from yahoo, I think you need to pay a subscription fee. Have you looked into writing a script that would download real time quotes from google? I would definitely be interested, especially if the script could let download several tickers at a same time listed in a string or text file.

  2. Lumilog on July 17th, 2009 10:37 am

    hi rigby,

    i wrote a quick matlab script to retrieve the last trade (real-time) from Google. here’s a link to it:

    get_last_trade_google.m

    i think matlab’s line-by-line execution doesn’t let you retrieve multiple tickers simultaneously though.

    best -
    - lumi

Leave a Reply