Good Day to all I have a problem transposing CSV file using python and pandas below are my codes.
import pandas as pd
df = pd.read_csv(r'TestData.csv')
df = df.groupby('Name')['Question'].apply(list)
df2 = df.T
df2.to_csv('file.csv')
I also attached the sample raw data and my needed output. Sample Screenshot