pandas dataframe count each time that a value appears in column code example Example: number of times a value occurs in dataframne df['a'].value_counts()