Merge column data into row in python
It's not hard at all. You have to transpose the second dataframe and add its values in the rows of the first dataframe. Use the .T command.
I have two dataframes :
1st dataframe

cat         2000    2001    2002    2003    2004    2005
1            779     771     754     740     760     747
2          1311.2   1285.2  1271.2  1276.5  1270.6  1281
3           836      814    810      800     802     799
4           914      892    888      878     880     877
5           992      970    966      956     958     955

2nd dataframe


year  data
2000  1
2001  4
2002  7
2003  10
2004  6
2005  3    


i would like to merge above these two dataframe in following way?is it possible?

cat         2000    2001    2002    2003    2004    2005
1           779     771     754      740     760    747
2          1311.2  1285.2   1271.2   1276.5 1270.6  1281
3           836      814    810      800     802    799
4           914      892    888      878     880    877
5           992      970    966      956     958    955
6(merge entry)1         4    7        10      6      3