I'm new to Python, and I'm trying to clean up a csv using Pandas.
My current dataframe looks like this:
Time Summary
0 10 ABC Company
1 4 Company XYZ
2 20 The Awesome Company
3 4 Record B
And I have a list that looks like:
clients = ['ABC', 'XYZ', 'Awesome']
The challenge I'm having is extracting values from the dataframe that equal any value in the list.
I'd like my dataframe to look like this:
Time Summary Client
0 10 ABC Company ABC
1 4 Company XYZ XYZ
2 20 The Awesome Company Awesome
3 4 Record B NaN
I've looked into regex, .any, and in, but I can't seem to get the syntax correct in the for loop.