Answers for "list comprehension unique values"

3

get list of unique values in pandas column

a = df['column name'].unique() #returns a list of unique values
Posted by: Guest on March-29-2021
3

how to find unique values in list in python

mylist = ['nowplaying', 'PBS', 'PBS', 'nowplaying', 'job', 'debate', 'thenandnow']
myset = set(mylist)
print(myset)
Posted by: Guest on February-25-2021

Python Answers by Framework

Browse Popular Code Answers by Language