man/examples/scr_getFundingrate.R

\dontrun{
# script start;

# 1) check available
# exchanges for funding rates
cryptoQuotes::available_exchanges(
  type = "fundingrate"
  )

# 2) get BTC funding rate
# for the last 7 days
tail(
  BTC <- cryptoQuotes::get_fundingrate(
    ticker = "BTCUSDT",
    source = "binance",
    from   = Sys.Date() - 7
  )
)

# script end;
}

Try the cryptoQuotes package in your browser

Any scripts or data that you put into this service are public.

cryptoQuotes documentation built on April 4, 2025, 2:33 a.m.