Skip to main content

Custom Google Sheets™ Functions

The tradeGIST add-on provides custom functions for advanced analysis of trades, assets, and snapshots. These can be used in any sheet cell for deeper insights. Below is a complete list with descriptions and examples.

Available Functions

ASSET_CURR(ticker)

Retrieves the trading currency for a specific asset.

Parameters:

  • ticker: The asset's symbol (e.g., "NVDA").

Example:

  • =ASSET_CURR("NVDA") returns "USD".

ASSET_FX_RATE(ticker)

Retrieves the current foreign exchange (conversion) rate from the asset's currency to the portfolio's base currency.

Parameters:

  • ticker: The asset's symbol (e.g., "NVDA").

Example:

  • =ASSET_FX_RATE("NVDA") returns the exchange rate (e.g., USD to EUR if the base currency is set to EUR).

ASSET_FX_RATE_AT(ticker, date)

Retrieves the historical foreign exchange (conversion) rate from the asset's currency to the portfolio's base currency for a specific date.

Parameters:

  • ticker: The asset's symbol (e.g., "NVDA").
  • date: The specific date for the historical exchange rate, typically formatted using the Google Sheets DATE(year, month, day) function.

Example:

  • =ASSET_FX_RATE_AT("NVDA", DATE(2026, 4, 16)) returns the exchange rate on April 16, 2026.

ASSET_HAS_SNAP(ticker)

Checks if an asset has "Take snapshot" activated. Returns TRUE or FALSE.
Example: =ASSET_HAS_SNAP("TSLA") returns TRUE if snapshots are enabled for TSLA.

ASSET_METRIC(ticker, account, metric)

Retrieves a specific performance data metric for an asset with an open position.

Parameters:

  • ticker: The asset's symbol (e.g., "TSLA").
  • account: The specific account name, or use the wildcard "*" to aggregate data across all accounts.
  • metric: The data point to retrieve. Must be one of: "total_value", "total_cost", "total_value_base_currency", "total_cost_base_currency", "shares", "contracts", "pl", "roi", "tax_value".

Examples:

  • =ASSET_METRIC("TSLA", "account_1", "roi") returns the overall Return on Investment (ROI) for TSLA within account_1 (including both shares and options).
  • =ASSET_METRIC("TSLA", "*", "total_value") returns the total market value of TSLA across all accounts.

ASSET_PRICE(ticker)

Retrieves the current price of an asset. This function reads the live value in the Asset configuration. Make sure to click "Update prices" to fetch the latest price.
Example: =ASSET_PRICE("NVDA") returns the latest NVDA price.

ASSET_SECTOR(ticker)

Retrieves the market sector for a specific asset. You can provide either a standard stock ticker or an options contract ticker.

Parameters:

  • ticker: The asset's symbol or options contract identifier (e.g., "GOOG" or "NVDA271217C00100000").

Example:

  • =ASSET_SECTOR("NVDA") returns the sector classification for Nvidia (e.g., "Information Technology").

ASSET_TYPE(ticker)

Retrieves the asset classification type (such as equity, crypto, or option) for a specific asset.

Parameters:

  • ticker: The asset's symbol or options contract identifier (e.g., "GOOG", "BTC", or "NVDA271217C00100000").

Examples:

  • =ASSET_TYPE("GOOG") returns "equity".
  • =ASSET_TYPE("BTC") returns "crypto".
  • =ASSET_TYPE("NVDA271217C00100000") returns "option".

CURR_RATE(currency)

Gets the current exchange rate to the base currency.
Example: =CURR_RATE("USD") returns the USD/EUR rate if base is EUR.

CURR_RATE_AT(currency, date)

Gets the exchange rate for a specific date.
Example: =CURR_RATE_AT("USD", DATE(2025,4,16)) returns the USD/EUR rate on April 16, 2025.

DIVIDEND_VALUE(ticker, value)

Retrieves a specific dividend-related metric for an asset.

Parameters:

  • ticker: The asset's symbol (e.g., "GOOG").
  • value: The dividend metric to retrieve. Must be one of: "dps" (dividend per share), "annualDps", "exDivDate", or "payoutDate".

Example:

  • =DIVIDEND_VALUE("GOOG", "dps") returns the current dividend per share (e.g., 0.25).

OPTION_DELTA(ticker)

Retrieves the Greeks delta value for a specific options contract from your Asset Configuration. Make sure to click "Update prices" first to fetch the latest data.

Parameters:

  • ticker: The options contract identifier (e.g., "NVDA250117C00300000").

Example:

  • =OPTION_DELTA("NVDA250117C00300000") returns the delta for that specific option.

OPTION_EXPIRY_DATE(ticker)

Returns the expiry date of the option contract.
Example: =OPTION_EXPIRY_DATE("NVDA281215C00300000") returns "December 15th 2028".

OPTION_IS_EXPIRED(ticker)

Evaluates whether an options contract has surpassed its expiration date. Returns TRUE or FALSE.

Parameters:

  • ticker: The options contract identifier (e.g., "NVDA251215C00300000").

Example:

  • =OPTION_IS_EXPIRED("NVDA251215C00300000") returns TRUE if the contract has expired.

OPTION_PRICE(ticker)

Returns the option contract price from Asset Configuration. Run "Update prices" first.
Example: =OPTION_PRICE("NVDA250117C00300000") returns the price for that option.

OPTION_ROOT_SYMBOL(ticker)

Retrieves the underlying stock symbol for a given options contract.

Parameters:

  • ticker: The options contract identifier (e.g., "NVDA281215C00300000").

Example:

  • =OPTION_ROOT_SYMBOL("NVDA281215C00300000") returns "NVDA".

OPTION_STRIKE_PRICE(ticker)

Retrieves the strike price of a given options contract.

Parameters:

  • ticker: The options contract identifier (e.g., "NVDA281215C00300000").

Example:

  • =OPTION_STRIKE_PRICE("NVDA281215C00300000") returns 300.

OPTION_TYPE(ticker)

Retrieves the option contract type (either "Call" or "Put") from your Asset Configuration.

Parameters:

  • ticker: The options contract identifier (e.g., "NVDA281215C00300000").

Example:

  • =OPTION_TYPE("NVDA281215C00300000") returns "Call".

Notes

  • Updates: Some functions (e.g., prices) require running "Update prices" or "Generate Trades" first.
  • Errors: If a function returns an error, check parameters and ensure data is available.