All examples By author By category About

timelyportfolio

EventDrops in R


Even though I resolved to not do any unpaid open-source this year, I unintentionally did not get paid on some work I did on an htmlwidget wrapper for the interactive EventDrops based on d3. So, here is an example of eventdropR.

Since I am still waiting for compensation, I assume I will never actually collect. I might as well contribute to the world. It is unfinished and still needs lots of improvement, but it does work.

Code

#devtools::install_github("timelyportfolio/eventdropR")

library(jsonlite)
library(eventdropR)
library(dplyr)
library(tibble)

# using example from https://cran.r-project.org/web/packages/jsonlite/vignettes/json-apis.html
fromJSON("https://api.github.com/repos/tidyverse/purrr/commits?per_page=100&since=2017-01-01") %>>%
  {
    tibble(
      name = .$commit$author$name,
      date = .$commit$author$date
    ) 
  } %>>%
  eventdrop(
    labelsWidth = 200
  )