library(taucharts)
library(tidyr)
fig16 <- read.table(text="Pattern,breaches_2013,incidents_2013,breaches_2011_2013
POS,14,1,31
Web App Attacks,35,6,21
Insider Misuse,8,18,8
Physical Theft/Loss,1,14,1
Miscellaneous Errors,2,25,1
Crimeware,4,20,4
Card Skimmers,9,1,14
DoS Attacks,0,3,0
Cyber Espionage,22,1,15
Everything Else,6,12,5", header=TRUE, sep=",", stringsAs=FALSE)
colnames(fig16) <- c("Pattern", "2013 breaches", "2013 incidents", "2011-2013 breaches")
fig16 <- gather(fig16, year, val, -Pattern)
tauchart(fig16, width=1400, height=500) %>%
tau_bar(c("year", "val"), c("Pattern"), color="Pattern", horizontal=TRUE) %>%
tau_guide_gridlines(FALSE, FALSE) %>%
tau_legend() %>%
tau_tooltip()