Current Data Frame output as below I need another Data Frame
import pandas as pd
df = pd.DataFrame('c:\data\text.csv')
print (df)
My output is as below:
a b c d e
0 1 10 {'a1':40,'b1':60,'c1':90,'d1':100,'e1':50,'f1':75} 10000 899
1 1 65 {'a1':35,'b1':535,c1': 343,'d1':89,'e1':67,'f1':45} 90000 789
Assume my index around 50,000 to 1,00,000
I tried:
df1=pd.DataFrame(list(df.c))
print(df1)
a1 b1 c1 d1 e1 f1
40 60 90 100 50 75
35 535 343 89 67 45
Then I tried
df2 = pd.DataFrame(df.a)
df3 = pd.DataFrame(df.b)
df4 = pd.DataFrame(df.d)
df5 = pd.DataFrame(df.e)
frames = [df1,df2,df3,df4,df5]
result = pd.concat(frames)
Still I am not able to get the expected result as below:
a b a1 b1 c1 d1 e1 f1 d e
0 1 10 40 60 90 100 50 75 10000 899
1 1 65 35 535 343 89 67 45 90000 789