Skip to content

Instantly share code, notes, and snippets.

@alistaire47
alistaire47 / keybase.md
Created October 28, 2017 02:57
keybase.md

Keybase proof

I hereby claim:

  • I am alistaire47 on github.
  • I am alistaire (https://keybase.io/alistaire) on keybase.
  • I have a public key ASCDokqb8qC26I5KvdqBatfUEG1x_I_64tywK32tK-CSrAo

To claim this, I am signing this object:

library(rvest)
library(purrr)
url <- 'http://www.basketball-reference.com/boxscores/201506140GSW.html'
tables <- url %>% read_html() %>% html_nodes('.sortable.stats_table')
headers <- tables %>% html_nodes(xpath = 'thead/tr[@class=""]') %>%
map(html_nodes, 'th') %>%
map(html_text)