One of the biggest news this week was Mircrosoft briefly overtaking Apple as the biggest company in terms of market cap. I thought it would be a good idea to graph this decade long catch-up.
Since I could not get historical market cap data as far out as 2010 directly using any API(without paying), I decided to use historical ticker prices & historical outstanding shares
Historical ticker prices fetched using AlphaVantage API.
Historical number of outstanding shares – Got this from sharesoutstandinghistory.com
Formula for Market Cap
Market Cap = Number of Outstanding Shares * Closing price
Python 3.6 Matplotlib Pandas AlphaVantage API
Related Posts:We truly are under attack. We need user support now more than ever! For as little as $10, you can support the IWB directly – and it only takes a minute. Thank you. 307 views