I have a dataframe in which contains different datatypes, here for example with two classes FirstGroup and LastGroup.
id1 id2 id3...
0 (0, FirstGroup.Other) (0, FirstGroup.Other) (0, FirstGroup.Static) ...
1 (60, LastGroups.Other) (22, LastGroups.Other) (49, LastGroups.Static) ...
All of these objects have data stored that I want to pull out in an efficient way. One example would be: df['id1'].[0][1].name will give me a string variable 'type1'.
I want to have something like this:
id1 id2 id3...
0 (0, 'type1') (0, 'type1') (0, 'type2') ...
1 (60, 'type1') (22, 'type1') (49, 'type2') ...
I am searching for something similar then the replace method but couldn't fine anything except looping over each row and column.