library(ggplot2)
library(plotly)
datums <- read.csv("~/Jeff/rSpace/Data/crabDatums1950To2016.csv")
p1 <- ggplot(datums, aes(x = Year, y = PoundsMillion, color = State))
ggplotly(p1 + geom_line())
p2 <- ggplot(datums, aes(x = State, y = PoundsMillion))
ggplotly(p2 + geom_point(aes(color = Year),
alpha = 0.5, size = 1.5,
position = position_jitter(width = 0.25,
height = 0)))
p3 <- ggplot(subset(datums, State %in% c("MD", "LA", "NC","VA")),
aes(x = Year, y = PoundsMillion, fill = State))
ggplotly(p3 + geom_area())
p4 <- ggplot(subset(datums,
State %in% c("MD", "VA", "NJ", "FL",
"LA", "NC", "SC","TX")),
aes(x = Region, y = PoundsMillion))
ggplotly(p4 + geom_point(aes(color = State),
alpha = 0.5, size = 2,
position = position_jitter(width = 0.25,
height = 0)))