Ticker#
- class yfinance.Ticker(ticker, session=None, proxy=<object object>)#
 Initialize a Yahoo Finance Ticker object.
- Parameters:
 ticker (str | tuple[str, str]) – Yahoo Finance symbol (e.g. “AAPL”) or a tuple of (symbol, MIC) e.g. (‘OR’,’XPAR’) (MIC = market identifier code)
session (requests.Session, optional) – Custom requests session.
Attributes
- actions
 
- analyst_price_targets
 
- balance_sheet
 
- balancesheet
 
- calendar
 Returns a dictionary of events, earnings, and dividends for the ticker
- capital_gains
 
- cash_flow
 
- cashflow
 
- dividends
 
- earnings
 
- earnings_dates
 
- earnings_estimate
 
- earnings_history
 
- eps_revisions
 
- eps_trend
 
- fast_info
 
- financials
 
- funds_data
 
- growth_estimates
 
- history_metadata
 
- income_stmt
 
- incomestmt
 
- info
 
- insider_purchases
 
- insider_roster_holders
 
- insider_transactions
 
- institutional_holders
 
- isin
 
- major_holders
 
- mutualfund_holders
 
- news
 
- options
 
- quarterly_balance_sheet
 
- quarterly_balancesheet
 
- quarterly_cash_flow
 
- quarterly_cashflow
 
- quarterly_earnings
 
- quarterly_financials
 
- quarterly_income_stmt
 
- quarterly_incomestmt
 
- recommendations
 
- recommendations_summary
 
- revenue_estimate
 
- sec_filings
 
- shares
 
- splits
 
- sustainability
 
- ttm_cash_flow
 
- ttm_cashflow
 
- ttm_financials
 
- ttm_income_stmt
 
- ttm_incomestmt
 
- upgrades_downgrades
 
Methods
- __init__(ticker, session=None, proxy=<object object>)
 Initialize a Yahoo Finance Ticker object.
- Parameters:
 ticker (str | tuple[str, str]) – Yahoo Finance symbol (e.g. “AAPL”) or a tuple of (symbol, MIC) e.g. (‘OR’,’XPAR’) (MIC = market identifier code)
session (requests.Session, optional) – Custom requests session.
- get_actions(proxy=<object object>, period='max') Series
 
- get_analyst_price_targets(proxy=<object object>) dict
 
- get_balance_sheet(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 - Parameters:
 - as_dict: bool
 Return table as Python dict Default is False
- pretty: bool
 Format row names nicely for readability Default is False
- freq: str
 “yearly” or “quarterly” Default is “yearly”
- get_balancesheet(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 
- get_calendar(proxy=<object object>) dict
 
- get_capital_gains(proxy=<object object>, period='max') Series
 
- get_cash_flow(proxy=<object object>, as_dict=False, pretty=False, freq='yearly') DataFrame | dict
 - Parameters:
 - as_dict: bool
 Return table as Python dict Default is False
- pretty: bool
 Format row names nicely for readability Default is False
- freq: str
 “yearly” or “quarterly” Default is “yearly”
- get_cashflow(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 
- get_dividends(proxy=<object object>, period='max') Series
 
- get_earnings(proxy=<object object>, as_dict=False, freq='yearly')
 - Parameters:
 - as_dict: bool
 Return table as Python dict Default is False
- freq: str
 “yearly” or “quarterly” or “trailing” Default is “yearly”
- get_earnings_dates(limit=12, offset=0) DataFrame | None
 
- get_earnings_estimate(proxy=<object object>, as_dict=False)
 
- get_earnings_history(proxy=<object object>, as_dict=False)
 
- get_eps_revisions(proxy=<object object>, as_dict=False)
 Index: 0q +1q 0y +1y Columns: upLast7days upLast30days downLast7days downLast30days
- get_eps_trend(proxy=<object object>, as_dict=False)
 Index: 0q +1q 0y +1y Columns: current 7daysAgo 30daysAgo 60daysAgo 90daysAgo
- get_fast_info(proxy=<object object>)
 
- get_financials(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 
- get_funds_data(proxy=<object object>) FundsData | None
 
- get_growth_estimates(proxy=<object object>, as_dict=False)
 Index: 0q +1q 0y +1y +5y -5y Columns: stock industry sector index
- get_history_metadata(proxy=<object object>) dict
 
- get_income_stmt(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 - Parameters:
 - as_dict: bool
 Return table as Python dict Default is False
- pretty: bool
 Format row names nicely for readability Default is False
- freq: str
 “yearly” or “quarterly” or “trailing” Default is “yearly”
- get_incomestmt(proxy=<object object>, as_dict=False, pretty=False, freq='yearly')
 
- get_info(proxy=<object object>) dict
 
- get_insider_purchases(proxy=<object object>, as_dict=False)
 
- get_insider_roster_holders(proxy=<object object>, as_dict=False)
 
- get_insider_transactions(proxy=<object object>, as_dict=False)
 
- get_institutional_holders(proxy=<object object>, as_dict=False)
 
- get_isin(proxy=<object object>) str | None
 
- get_major_holders(proxy=<object object>, as_dict=False)
 
- get_mutualfund_holders(proxy=<object object>, as_dict=False)
 
- get_news(count=10, tab='news', proxy=<object object>) list
 Allowed options for tab: “news”, “all”, “press releases
- get_recommendations(proxy=<object object>, as_dict=False)
 Returns a DataFrame with the recommendations Columns: period strongBuy buy hold sell strongSell
- get_recommendations_summary(proxy=<object object>, as_dict=False)
 
- get_revenue_estimate(proxy=<object object>, as_dict=False)
 
- get_sec_filings(proxy=<object object>) dict
 
- get_shares(proxy=<object object>, as_dict=False) DataFrame | dict
 
- get_shares_full(start=None, end=None, proxy=<object object>)
 
- get_splits(proxy=<object object>, period='max') Series
 
- get_sustainability(proxy=<object object>, as_dict=False)
 
- get_upgrades_downgrades(proxy=<object object>, as_dict=False)
 Returns a DataFrame with the recommendations changes (upgrades/downgrades) Index: date of grade Columns: firm toGrade fromGrade action
- history(*args, **kwargs) DataFrame
 
- live(message_handler=None, verbose=True)
 
- option_chain(date=None, tz=None)