I have a code where I see which people work in certain groups. When I ask the leader of each group to present those who work for them, in a survey, I get a row of all of the team members. What I need is to clean the data into multiple rows with their group information.

I don't know where to start.

This is what my data frame looks like,

```
LeaderName <- c('John','Jane','Louis','Carl')

Group <- c('3','1','4','2')

Member1 <- c('Lucy','Stephanie','Chris','Leslie')

Member1ID <- c('1','2','3','4')

Member2 <- c('Earl','Carlos','Devon','Francis')

Member2ID <- c('5','6','7','8')

Member3 <- c('Luther','Peter','','Severus')

Member3ID <- c('9','10','','11')

GroupInfo <- data.frame(LeaderName, Group, Member1, Member1ID, Member2 ,Member2ID, Member3, Member3ID)

```

This is what I would like it to show with a certain code

```
LeaderName_ <- c('John','Jane','Louis','Carl','John','Jane','Louis','Carl','John','Jane','','Carl')

Group_ <- c('3','1','4','2','3','1','4','2','3','1','','2')

Member <- c('Lucy','Stephanie','Chris','Leslie','Earl','Carlos','Devon','Francis','Luther','Peter','','Severus')

MemberID <- c('1','2','3','4','5','6','7','8','9','10','','11')

ActualGroupInfor <- data.frame(LeaderName_,Group_,Member,MemberID)

```