Question: Write a R code with following question In column of a dataframe, we have stored strings that tell us if someone likes orange juice, apple

Write a R code with following question

Write a R code with following question In column of a dataframe,

In column of a dataframe, we have stored strings that tell us if someone likes orange juice, apple juice etc. Extract the names of students who like orange juice or oranges. Expected Output: Annie Harry Hint: Use `str_detect before using str_extract() O myVar = c( "Annie likes Orange juice", "Sonny likes Apple juice", "Katy dislikes Orange juice", "Harry likes Oranges", "Charlie likes Apple juice", "Margo like Orange Pie") df = data. frame(myVar) {r} # your code

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Mathematics Questions!