ranaroussi / yfinance

Download market data from Yahoo! Finance's API
https://aroussi.com/post/python-yahoo-finance
Apache License 2.0
14.93k stars 2.45k forks source link

Currency data for statements #1976

Closed mking007 closed 4 months ago

mking007 commented 4 months ago

Describe bug

Currency data for financial statements

For some stocks, like BP.L, the share price data is GBp whereas the financial statements are in USD.

The currency of GBp is available in fast_info but the currency (USD) for the financial statements does not appear to be available.

Am I missing something?

Simple code that reproduces your problem

import yfinance as yf ticker = yf.Ticker("BP.L") ticker.info['currency']

Debug log

not a bug

Bad data proof

ticker.info['currency'] 'GBp'

yfinance version

0.2.40

Python version

No response

Operating system

No response

ValueRaider commented 4 months ago

I had a quick look:

info['financialCurrency']

No idea how reliable that is.

ValueRaider commented 4 months ago

It's reliable.

mking007 commented 4 months ago

This works. Closed issue. Thanks :)