Investigating Cryptocurrencies using R

R-bloggers 2017-07-16

Summary:

Cryptocurrencies are a fascinating phenomenon and excellent data source for analysis with R.  This post will introduce how to get a list of available currencies into R.  Wikipedia maintains a page with a list of cryptocurrencies.  These can be read from HTML into a data frame.library(httr)library(XML)results = GET("https://en.wikipedia.org/wiki/List_of_cryptocurrencies")doc = readHTMLTable(doc=content(results, "text"))View(doc[1])This list is not complete.  Also, an API would be preferable to reading a wiki page.  A publicly available API at cryptocompare.com provides similar information in JSON format.library(jsonlite)library(data.table)response = fromJSON('https://www.cryptocompare.com/api/data/coinlist')df = data.table::rbindlist(response$Data, fill=TRUE)View(df)With a bit of shiny code, this data can be served up in a web application and published to shinyapps.io... so you can skip the R coding and review the data here if you prefer:https://casimir.shinyapps.io/cryptocurr/

Link:

http://feedproxy.google.com/~r/RBloggers/~3/v_I0rd2tsvs/

From feeds:

Statistics and Visualization » R-bloggers

Tags:

Authors:

C

Date tagged:

07/16/2017, 01:25

Date published:

07/15/2017, 18:36