Skip to contents

Class for retrieving all data related to a single ticker from the Yahoo Finance API. Inherits get_history() from YahooFinanceBase-class.

Format

An R6 class object

See also

Super class

yahoofinancer::YahooFinanceBase -> Ticker

Active bindings

valuation_measures

Retrieves valuation measures

recommendations

Related symbols recommended by Yahoo Finance and their scores.

technical_insights

Technical insights and indicators snapshot.

currency

Currency code for the symbol.

exchange_name

Short name of the stock exchange.

full_exchange_name

Full name of the stock exchange.

first_trade_date

Timestamp of the first recorded trade.

regular_market_time

Timestamp of the last market trade.

timezone

Timezone code of the exchange.

exchange_timezone_name

Full timezone name of the exchange.

regular_market_price

Current regular market price.

fifty_two_week_high

52-week high price.

fifty_two_week_low

52-week low price.

regular_market_day_high

Highest price during the current trading session.

regular_market_day_low

Lowest price during the current trading session.

regular_market_volume

Current trading volume.

previous_close

Closing price of the previous trading day.

Methods

Inherited methods


Method new()

Create a new Ticker object.

Usage

Ticker$new(symbol = NA)

Arguments

symbol

Symbol (e.g., "AAPL").


Method set_symbol()

Set a new symbol and clear cached metadata.

Usage

Ticker$set_symbol(symbol)

Arguments

symbol

New symbol (e.g., "AAPL").


Method get_income_statement()

Retrieve income statement data.

Usage

Ticker$get_income_statement(frequency = c("annual", "quarterly"))

Arguments

frequency

One of "annual" or "quarterly". Defaults to "annual".

Returns

A tibble with columns date, period_type, and income statement line items, or invisible(NULL) on failure.


Method get_balance_sheet()

Retrieve balance sheet data.

Usage

Ticker$get_balance_sheet(frequency = c("annual", "quarterly"))

Arguments

frequency

One of "annual" or "quarterly". Defaults to "annual".

Returns

A tibble with columns date, period_type, and balance sheet line items, or invisible(NULL) on failure.


Method get_cash_flow()

Retrieve cash flow statement data.

Usage

Ticker$get_cash_flow(frequency = c("annual", "quarterly"))

Arguments

frequency

One of "annual" or "quarterly". Defaults to "annual".

Returns

A tibble with columns date, period_type, and cash flow statement line items, or invisible(NULL) on failure.


Method clone()

The objects of this class are cloneable with this method.

Usage

Ticker$clone(deep = FALSE)

Arguments

deep

Whether to make a deep clone.