Skip to content

Python code snippet – How to get unique value of all columns in pandas?

a = df['column name'].unique() #returns a list of unique values
See also  Python code snippet - How to convert an image to ascii art ?

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.