I'm using RStudio, and I have one dataframe containing a list of candidates, and a dataframe containing all votes of each voting location, and by candidate.
I want to extract only the rows containing the votes of the candidates of this list.
Example:
List:
Candidate A B D GVotes:
Candidate Number of Votes A 124 B 52 C 13 D 62 E 33 F 7 G 67
I want then to create a new dataframe containing only the candidates and votes of the "List":
Votes of listed candidates:
Candidate Number of Votes A 124 B 52 D 62 G 67
The example is a simplification. My database contains over 30.000 "candidates"
Thanks in advance