td_get_current: Returns current TD prices and yields

View source: R/td_get_current.R

td_get_currentR Documentation

Returns current TD prices and yields

Description

Fetches current prices and yields of Tesouro Direto (TD) assets by downloading the latest daily data available from the website.

Usage

td_get_current(asset_codes = NULL, dl_folder = get_cache_folder())

Arguments

asset_codes

A character vector identifying the assets (e.g., 'LTN', 'NTN-B'). If 'NULL', returns all available assets.

dl_folder

Path of the folder to save Excel files from Tesouro Direto. Defaults to a session-temporary directory.

Value

A tibble with current asset prices, yields, and maturity dates.

Examples

## Not run: 
df_current <- td_get_current()
head(df_current)

## End(Not run)

GetTDData documentation built on Aug. 29, 2026, 5:07 p.m.