Created
December 29, 2016 13:58
-
-
Save flovv/437d6d30b5a1f92e5c482b36f70c69ab to your computer and use it in GitHub Desktop.
appendix to a blog post
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require(ggplot2) | |
require(ggthemes) | |
require(rvest) | |
require(plyr) | |
url <- "http://rodrigob.github.io/are_we_there_yet/build/classification_datasets_results.html" | |
ml <- read_html(url) | |
tabs <- ml %>% html_nodes(xpath='//*[@class="table table-striped"]') %>% html_table() | |
df <- tabs[[1]] | |
df$dataset <- "MINST" | |
dsNames <- c("MINST","CIFAR-10", "CIFAR-100", "STL-10", "SVHN") | |
for(i in 2:5){ | |
tab <- tabs[[i]] | |
tab$dataset <- dsNames[i] | |
df <- rbind(df,tab) | |
} | |
df$year <- as.numeric(str_sub(df$Venue, nchar(df$Venue)-4, nchar(df$Venue))) | |
df$res <- as.numeric(str_split_fixed(df$Result, "%", 2)[,1]) | |
### code it all to error! | |
df$res2 <- ifelse(df$res > 50, 100- df$res , df$res) | |
dd <- ddply(df, .(year, dataset), summarise, m=min(res2), max=max(res2), trimmedMean =mean(res2, trim=.1)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment