Add VT2-examples: all 6 chapters of 'Visualize This' (110 files) — data scraping, ETL, trends, categorical, multivariate, spatial, distribution analysis
This commit is contained in:
1 parent
088771a9cf
commit
b42b866a8c
110 files changed
+400895
No files matched your search
@@ -0,0 +1,24 @@
|
||||
# Install package if have not yet
|
||||
# install.packages("treemap")
|
||||
|
||||
# Load package.
|
||||
library(treemap)
|
||||
|
||||
#
|
||||
# Load data.
|
||||
#
|
||||
howmet2010 <- read.csv("data/how-met-2010s.tsv", sep="\t")
|
||||
|
||||
|
||||
#
|
||||
# Draw treemap.
|
||||
#
|
||||
|
||||
treemap(howmet2010,
|
||||
index = c("category", "waymet"),
|
||||
vSize = "p",
|
||||
algorithm = "squarified",
|
||||
title = "How People Met, 2010s")
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user