I have a large dataframe df which looks as following, where each value in column Col2 is itself a list:
Col1 Col2
R1 ['C1']
R2 ['C1', 'C2']
R3 ['C1']
I want to get the following:
Col1 Col2
R1 ['C1']
R3 ['C1']
I am trying the following:
df[df['Col2'] == ['C1']]
But it is not generating desired results.
Edit: I am trying to get the rows where Col2 contains the list with only values ['C1'] and not ['C1', 'C2'], etc