Closed dvirginz closed 7 months ago
The MarketCap history doesn't seem to be available on yahoo finance and if you wanted to build the MarketCap history from the history of the stock prices, you would also need the history of outstanding shares. You can maybe assume constant number of outstanding shares over a short recent period and multiply it by your stock price history to get your market cap numbers.
Yes, unfortunately, as you know, this is not a fair assumption
On Sun, Jul 3, 2022, 13:22 AntoineV @.***> wrote:
The MarketCap history doesn't seem to be available on yahoo finance and if you wanted to build the MarketCap history from the history of the stock prices, you would also need the history of outstanding shares. You can maybe assume constant number of outstanding shares over a short recent period and multiply it by your stock price history to get your market cap numbers.
— Reply to this email directly, view it on GitHub https://github.com/ranaroussi/yfinance/issues/1008#issuecomment-1173054135, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHM4A75CTVXLO4K6HR2UWC3VSFSWVANCNFSM5XDMUT3A . You are receiving this because you authored the thread.Message ID: @.***>
I'm reopening this because I have a solution: branch feature/share-count
will provide you a few years of share count. It's a weird mix of daily, weekly and monthly. Combine with price for MarketCap.
If you want to try now and give feedback, this discussion explains how to download. Use property shares_full
Ticker.get_shares_full()
is your friend.
Ticker.get_shares_full()
is your friend
It seems that sometimes get_shares_full() give wrong results. For example, get_shares_full() outputs two different shares of MSFT on 20240501
I don't understand the data oddities in that API call, I discovered it by accident.
Using the provided code we can fetch one of the following data points
1) The current MarketCap 2) Historical data of Open High Low Close and Volume
Can we somehow can historical information of the marketcap?
Thanks.