I have a transcribed interview and the data is organized as follows:
[1,] "Interviewer"
[2,] "What is your favorite food?"
[3,] "Interviewee"
[4,] "I love to eat pizza"
[5,] "Interviewer"
[6,] "Cool. But have you ever tried eating salad?"
[7,] "Interviewee "
[8,] "Yeah..."
[9,] "Interviewer"
[10,] "I love salad, pizza is bad."
[11,] "Interviewee "
[12,] "I don't totally agree"
I would like to remove the author of the speech from the rows and turn it into a categorical column, as in the example:
[,1] [,2]
[1,] "Interviewer" "What is your favorite food?"
[2,] "Interviewee" "I love to eat pizza"
[3,] "Interviewer" "Cool. But have you ever tried eating a salad?"
[4,] "Interviewee" "Yeah..."
[5,] "Interviewer" "I love salad, pizza is bad."
[6,] "Interviewee" "I don't totally agree"
The interview considers the conversation between two people. Does anyone know how to do this? Thanks in advance!