'Adding a column to a DataFrame and combining them

I have created four DataFrames and then I added a column to them and then combined them into a single data frame but NaN appeares in the values of the column that I've added this is the code of adding the period column

 bldg_2009_10_df['Period']="2009-10"
bldg_2010_11_df['Period']="2010-11"
bldg_2011_12_df['period']="2011-12"
bldg_2012_13_df['Period']="2012-13"

and here I have combined them into a single DataFrame

concat_inner_mydf=pd.concat([bldg_2009_10_df,bldg_2010_11_df,bldg_2011_12_df,bldg_2012_13_df])
concat_inner_mydf


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source