Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
Generate bar plot of databases in NAR annual issue
dblink <- "https://docs.google.com/spreadsheet/pub?key=0Amd94LRhVxVWdElNYVdHblVLRjZKR1lwaFFFZHVyWUE&single=true&gid=0&output=csv"
require(RCurl)
myCsv <- getURL(dblink)
dbs <- read.csv(textConnection(myCsv))
library(ggplot2)
names(dbs) <- c("Year","Databases")
dbs[[1]] <- as.factor(dbs[[1]])
p <- qplot(x=Year,y=Databases,data=dbs,geom="bar",fill="gray")
p + theme_bw() + opts(axis.text.x = theme_text(angle=90, hjust=1.2, size=16),
axis.title.x=theme_text(size=16),
axis.title.y=theme_text(size=16,angle=90),
axis.text.y = theme_text(size=16),
legend.position="none") +
ylab("Databases in NAR Database issue")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment