I'm struggling to find a solution, I want to transform the following dataframe:
d = {'Group': ['A', 'A', 'A', 'B', 'B', 'B'],
'Person': ['Andrew', 'Carl', 'Karen' , 'Violet', 'Jennifer', 'Taylor'],
'Value 1': [1000, 5000, 5000, 2000, 9000, 5000],
'Value 2': [2000, 1000, 3000, 1000, 8000, 6000],
'Value 3': [5000, 2000, 4000, 4000, 7000, 5000]}
df = pd.DataFrame(data=d)
Original dataframe:
Into a dataframe with the following structure:
I've look in multiple posts, but the answer does not help me. Any contribution helps a lot, I need a dataframe as the desired output to use it as a table in Power BI.
Thank you