I have two column series - A series and B series.
df <- data.frame(A_1_1 = 'a',
A_2_1 = 'b',
A_3_1 = 'c',
B_0_1 = 'x',
B_0_2 = 'y',
B_0_3 = 'z'
)
I need to concatenate the A series with B series in the same sequence, to get the desired output.
Attempting something to this effect:
df %>% str_c(starts_with("A_"),"-",starts_with("B_"))
Thanks in advance!
