Intro cheat sheet
install.package("ggplot2")
library(ggplot2)
head(diamonds)
str(diamonds)
qplot(carat, price, data=diamonds)
qplot(log(carat), log(price), data=diamonds)
qplot(carat, price/carat, data=diamonds)
qplot(carat, price, data=diamonds, colour=color)
qplot(carat, price, data=diamonds, size=carat)
qplot(carat, price, data=diamonds, shape=cut)
qplot(price, carat, data=diamonds, facets = . ~ color)
qplot(price, carat, data=diamonds, facets = color ~ clarity)
qplot(cut, data=diamonds, geom="bar")
qplot(price, data=diamonds, geom="histogram")
qplot(price, data=diamonds, geom="histogram", binwidth=500)
qplot(price, data=diamonds, geom="histogram", binwidth=100)
qplot(price, data=diamonds, geom="histogram", binwidth=10)