0

I am new to Python and could use some help. I am trying to append 2 dataframes to a single sheet in excel side by side.

'botCarDfA = pd.DataFrame(botdfA[['Car','Current Track-Sequence']])'
'botCarDfC = pd.DataFrame(botdfC[['Car','Current Track-Sequence']])'
'botCarDf = pd.concat([botCarDfA, cabotCarDfC], axis=1)'

I am trying to attach botCarDfA and botCarDfC side by side but this is what I get

    '            Car Current Track-Sequence         Car Current Track-Sequence'
            Car Current Track-Sequence         Car Current Track-Sequence
32  CABX 470586               A030-005         NaN                    NaN
33  CABX 470594               A030-003         NaN                    NaN
38   TCMX 96358               A030-004         NaN                    NaN
77          NaN                    NaN  TCMX 96159               C017-013
78          NaN                    NaN  TCMX 96235               C017-015
79          NaN                    NaN  TCMX 96290               C017-014

I would like these to be side by side not diagnally attached so I can append them that way in an excel sheet.

0 Answers0