unique values counts code example Example: values of unique from dataframe with count data = df.groupby('ColumnName')['IDColumnName'].nunique() print(data)