I am doing a python exercise.
One of the columns in my dataframe has the following values:
df_house_sample.house_type_id.values
array(['HouseType 1: Pisos', 'HouseType 1: Pisos', 'HouseType 1: Pisos',
..., 'HouseType 1: Pisos', 'HouseType 2: Casa o chalet',
'HouseType 1: Pisos'], dtype=object)
I need to retrieve all housing types left after the colon. Like for example "Floors".
I've used a loop and regex, but I can't get the housing type back.
Thanks in advance. All the best.
If the structure is that you can do a split and get the second element that will always be after the colon.