I have a large dataframe where I want to filter for a value "Y" , if present in multiple columns.
If so, then I will have to create a new character column and assign value 1 there otherwise, need to assign blank where the condition doesn't match. NB: the columns are not next to each other neither they carry any common string in their names. As a SAS professional I'm familiarized with arrays to solve this and as a beginner in R, would really like to explore the methods to approach this problem. Would really appreciate if, one can guide please. Thanks!!