I was trying to merge the X and Y axis of the plots generated by using the following code like subplot has shareX and shareY argument to merge the X and Y axis of different plots.
library(dplyr)
library(echarts4r)
df <- list(a = data.frame(var = rep("type1", times = 18)),
b = data.frame(var = rep("type2", times = 18)),
c = data.frame(var = rep("type3", times = 18)),
d = data.frame(var = rep("type4", times = 18)),
e = data.frame(var = rep("type5", times = 18)),
f = data.frame(var = rep("type6", times = 18)))
df <- df %>%
purrr::map(., ~ dplyr::mutate(., count = row_number()))
plot_list <- list()
for(i in 1:length(df)){
plot_list[[i]] <- df[[i]] %>%
e_charts(var) %>%
e_scatter(count,
symbol_size = 5) %>%
e_x_axis(var, axisLabel = list(interval = 0L, rotate = 45)) %>%
e_legend(show = FALSE)
}
e_arrange(plot_list[[1]], plot_list[[2]], plot_list[[3]], plot_list[[4]], plot_list[[5]], plot_list[[6]], rows = 1, cols = 6)
Is it possible to do using e_arrange?