2021-01-04 17:10:29 +01:00
|
|
|
library(apexcharter)
|
|
|
|
|
|
|
|
# Scatter ----
|
|
|
|
|
|
|
|
data("mpg", package = "ggplot2")
|
|
|
|
|
|
|
|
# Only rows
|
|
|
|
apex(mpg, aes(displ, cty), type = "scatter") %>%
|
|
|
|
ax_facet_grid(rows = vars(drv), chart_height = "200px")
|
|
|
|
|
|
|
|
# Only cols
|
|
|
|
apex(mpg, aes(displ, cty), type = "scatter") %>%
|
|
|
|
ax_facet_grid(cols = vars(year))
|
|
|
|
|
|
|
|
# Rows and Cols
|
|
|
|
apex(mpg, aes(displ, cty), type = "scatter") %>%
|
|
|
|
ax_facet_grid(rows = vars(drv), cols = vars(year))
|
|
|
|
|
2021-01-05 11:11:24 +01:00
|
|
|
apex(mpg, aes(displ, cty), type = "scatter") %>%
|
|
|
|
ax_facet_grid(vars(drv), vars(cyl))
|