R/data.R
These helpers return ID, name or ticker symbol for cryptocurrencies based on either of the other two. Symbol inputs are not case sensitive but IDs and names are.
coin_id(x) coin_name(x) coin_symbol(x)
x | a coin id, name or ticker symbol. |
---|
a vector the same length as x
.
coin_id(c("btc", "Ethereum"))#> [1] "bitcoin" "ethereum"coin_name(c("BTC", "BCH"))#> [1] "Bitcoin" "Bitcoin Cash"coin_symbol("Bitcoin")#> [1] "BTC"