Example of code to illustrate my issue here.
table_A <- tibble(A1 = c("a", "a/b"), A2 = seq(1,2))
table_A <- table_A %>% mutate(A1 = str_split(A1, "/"))
table_B <- tibble(A1 = c("a","b"), B1 = c("apple", "bananas"))
#does not work
#left_join(table_A, table_B)
The desired result would be to have a new B1 column with c("apple") and c("apple", "bananas") but obviously this code does not work. In practice the lists range from no key to 5 keys long. Happy to take any suggestions, maybe there is a way to re-frame the data or th problem to solve it elegantly.