.nunique() python code example Example: nunique in python # to find the count of unique values. idx.nunique(dropna = True)