Get kline/candlestick data from Binance

binance_klines(
  symbol,
  interval = c("1m", "3m", "5m", "15m", "30m", "1h", "2h", "4h", "6h", "8h", "12h",
    "1d", "3d", "1w", "1M"),
  limit,
  start_time,
  end_time
)

Arguments

symbol

string

interval

enum

limit

optional int

start_time

optional POSIX timestamp

end_time

optional POSIX timestamp

Value

data.table with open-high-low-close values

Examples

if (FALSE) {
binance_klines('ETHUSDT')
binance_klines('ETHUSDT', interval = '1h', limit = 24*7)
binance_klines('ETHUSDT', interval = '1h', start_time = '2018-01-01', end_time = '2018-01-08')
}