Download financial data using the Yahoo API
If you want to consult financial information, Yahoo! Finance is a good site for that. For instance, to get info about Microsoft’s shares, just visit http://finance.yahoo.com/q?s=msft&ql=1. There, in the bottom right corner in the Toolbox section, you can find a link “Download Data”.
But is there another way to get financial data? Is there a Yahoo API for this?
The answer to the previous question is: yes, there is. Visit http://www.gummy-stuff.org/Yahoo-data.htm for a detailed presentation of the API.
Here we ask stock information about the shares of Microsoft. Their stock code is “MSFT”. We pass four parameters:
n – stock name,
l1 – current price,
p – price at the previous close,
x – stock exchange. The data is returned as a text file in .csv format:
This can help you to choose the parameters that you really need.