count elements occurrences in dataframe code example
Example 1: python - count number of occurence in a column
print df
col1 education
0 a 9th
1 b 9th
2 c 8th
len(df[df['education'] == '9th'])
Example 2: count specific instances in a columb in pandas
df.describe(include=['O']) # give count of unieque categorical