Is there a way to map
characters
for a column
in Pandas
.
For example, I would like to map a column say info
like this {"1": "US", "2":"DE", "3":"CA", "4":"AU", "5":"BE"}
So instead of the numbers, I would like something US
and the rest to show
EDIT NOTE: I dont want to explode the column, I want to keep them as they are, only replacing numbers with strings
0 ['3']
1 ['6']
2 ['3','4']
3 ['3','4','6']
4 ['3','4']
5 ['6']
6 ['6']
7 ['5']
8 ['5']
9 ['3', '4', '1']