My data starts with a pandas dataframe. Then I convert the column which I am interested in into a python list and I am trying to join certain elements of that list into one