Extract Column from Tables
I have some census data, which are 20 excel files for 20 year respectively (1980 - 1999). Each of the files contains county names and corresponding census data, e.g., GRDP, population, education.
The aim is to get GDP data from each year, and save them in one excel file.
I used Python 3.7 pandas packge to solve this problem.
Function 1: get GPD column from a excel file
# get GRDP and name from a certain year
Function 2: join a column to an existing table
# join a table to the table of 1999
Add all the GPD column to the global variable
for i in range(1998, 1980, -1):