Learn R Programming

crypto (version 1.0.3)

getExchanges: Get current crypto market exchanges

Description

Scrape the crypto currency exchange tables from CoinMarketCap <https://coinmarketcap.com> and display the results in a date frame. This can be used to conduct analysis on the exchanges or to attempt to predict exchange arbiture.

Usage

getExchanges(coin = NULL, limit = NULL, cpu_cores = NULL,
  start_date = NULL, end_date = NULL)

crypto_exchanges(coin = NULL, limit = NULL, cpu_cores = NULL, start_date = NULL, end_date = NULL)

Arguments

coin

string Name, symbol or slug of crypto currency, default is all tokens

limit

integer Return the top n records, default is all tokens

cpu_cores

integer Uses n cores for processing, default uses all cores

start_date

string Start date to retrieve data from, format 'yyyymmdd'

end_date

string End date to retrieve data from, format 'yyyymmdd'

...

No arguments, return all coins

Value

Crypto currency historic OHLC market data in a dataframe:

slug

Coin url slug

symbol

Coin symbol

name

Coin name

trading_pair

Coin trading pair

exchange_name

Name of exchange

last_updated

Exchange refresh

exchange_volume

Exchange $USD volume

exchange_price

Exchange $USD price

exchange_share

Percent exchange traded

coin_rank

Rank of current coin

exchange_rank

Exchange ranking for coin

If you want to retrieve ALL coins and their exchanges, then do not pass a argument to getExchanges(),

Please note that the doSNOW package is required to load the progress bar on both linux and macOS systems as the doParallel package does not support it.

Examples

Run this code
# NOT RUN {
# Retrieving exchange data for specific crypto currency

coin <- "kin"
kin_exchanges <- getExchanges(coin)

# retrieving market history for ALL crypto currencies

all_exchanges <- getExchanges()

# }

Run the code above in your browser using DataLab