I've got a dataframe which looks like this:
Record Field11 ID LesionNumber Diagnosis1
1 False 1000 1 22
1 False 1000 2 88
1 False 1000 3 22
1 False 1000 4 24
All of the ID's are the same. And this kind of structure repeats for many different ID's.
Using all rows with the same ID, I'd like to create a new dataframe which looks like this:
Record ID LesionNumber Diagnosis1
1 1000 1, 2, 3, 4 22, 88, 22, 24
I'd like to have the LesionNumber and Diagnosis1 appear as ordered lists.
I'm new to Pandas and dataframes so my terminology may be off. Is this possible?