I want to find the amount of occurrences of a string variable across multiple variables by different groups. There's a large number of variables with various names so they might have to be renamed but I don't know how to do that either, note that this fact also makes it difficult for me to use the reshape command even though that might be a solution as well.
Here's an example:
ID | V1 | V2 | V3 | count_relevant_string |
1 | relevant_string | relevant_string | Gibberish word | 2 |
2 | Gibberish word | Gibberish word | relevant_string | 1 |
3 | Gibberish word | Gibberish word | Gibberish word | 0 |
Thanks in advance
Jonatan
0 Response to Find occurrences of string across multiple variables
Post a Comment