Download historical financial data from Yahoo!
Retrieves historical stock data for the ticker symbols in Asset cell array (ticker symbol and yahoo stock exchange symbol), between the dates specified by Date1 (beginning) and Date2 (end) in the Matlab datenums format. The program returns the stock data in xls at '/Data' folder, giving the Date, Open, High, Low, Close, Volume, and Adjusted Close price adjusted for dividends and splits.
For PERSONAL, INFORMATIONAL use ONLY.
-------------------------------------------------------------------------------------------------------------------------------------
Example:
Asset = {
'AAPL','';
'ANA','MC';
'BKIA','MC';
'CDR','MC';
'ENG','MC';
'GLD','';
'IAG','MC';
'LYXIB','MC';
'MT','AS';
'OHL','MC';
'ITX','MC';
'SAN','MC';
'TEF','MC'
};
Asset = table(Asset(:,1), Asset(:,2), 'VariableNames', {'Symbol', 'SE'});
Date1 = '26-Jan-2017';
Date2 = '27-Jan-2018';
interval = '1d';
downloadStocksData(Asset,Date1,Date2,interval)
Cite As
Aitor Roca (2024). Download historical financial data from Yahoo! (https://www.mathworks.com/matlabcentral/fileexchange/64218-download-historical-financial-data-from-yahoo), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform Compatibility
Windows macOS LinuxCategories
- MATLAB > Data Import and Analysis > Data Import and Export > Web Access and Streaming > Web Services >
- Computational Finance > Datafeed Toolbox > Financial Data > Money.Net >
Tags
Acknowledgements
Inspired: Yahoo! Finance Data Loader
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.