I am trying to make a certain alluvial plot with different widths specified in different columns. Let me try to explain it by drawing it, as I am not sure how to do this in ggalluvial.
Notice that the width of the flow from the Male box represents 3 units, while it represents 10 in box 3. Is it possible to create such graphs in ggalluvial? Or how can one construct such a graph in R?
I haven't drawn the other flows just to focus on the flow from male to 3.
I would hereby would like to present some data to create such a graph:
test_data <- data.table(`2018 - Gender` = c("Male", "Female", "Female", "Male"),
`2018 - Value` = c(10, 20, 30, 20),
`2019 - Gender` = c("Male", "Female", "Male", "Female"),
`2019 - Value` = c(20, 30, 10, 10)
)
Notice that the column names determine the "columns" in the graphs (i.e. the x-axis). While the Gender variable determines the blocks. The value from 2018 is the starting width, while the value from 2019 is the ending width of the strata.
As some have pointed out that I need to put more focus on my question. The question is how to make flow graphs with different starting and ending width.