this is practice for knitting trelliscope plots to html files
# load libraries
library(ggplot2)
library(trelliscopejs)
library(tidyverse)
# load in data
tx <- read.csv("tx.csv")
# make it a tibble
tx <- as_tibble(tx)
# trelliscope plot
tx %>%
filter(tip_amount < 12) %>%
ggplot( aes(x = tip_amount)) +
geom_histogram() +
ylim(c(0, 1200)) +
facet_trelliscope(~ pick_day,
name = "Date",
desc = "Route dat from 7/01/2016 - 12/31/2016",
nrow = 2, ncol = 3,
path = ".", # will specify the same folder that the markdown is in
self_contained = TRUE) # will knit just the trelliscope graph (not the whole doc) straight to a webpage