I know that to count each unique value of a column and turning it into percentage I can use:
df['name_of_the_column'].value_counts(normalize=True)*100
I wonder how can I do this for all the columns as a function and then drop the column where a unique value in a given column has above 95% of all values? Note that the function should also count the NaN values.