I have an example dataframe
df = data.frame(day = c("Monday", "Tuesday; Wednesday", "Thursday"),
c(2, 3, 5))
I want to separate all strings with "; " and assign the value of the second column like this:
df_goal = data.frame(value= c("Monday", "Tuesday", "Wednesday", "Thursday"),
c(2, 3, 3, 5))
My original data is much larger so I am looking for larger scale applicable solution