I want to create a new column in Pandas using a string sliced for another column in the dataframe.
Sample Value New_sample AAB 23 A BAB 25 B
New_sample is a new column formed from a simple
[:1] slice of
I've tried a number of things to no avail – I feel I'm missing something simple.
What's the most efficient way of doing this?