I need to create a dataframe filtering out the five most frequently listed countries in the Nationality column and the total amount of times they are listed. I've been trying to use groupby, but have been unsuccessful. The code i've used it
df.groupby(['Nationality']).sum()
I also need to determine what percent of those listed as participating in the program have at least one referral. I'm not sure the code for this either though.