<s> """<STR_LIT>""" <EOL> import pandas as pd <EOL> import glob <EOL> df = pd . read_csv ( '<STR_LIT>' , sep = "<STR_LIT:;>" ) <EOL> df . columns = [ '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' , '<STR_LIT>' , '<STR_LIT>' , <EOL> '<STR_LIT>' ] <EOL> files = glob . glob ( '<STR_LIT>' ) <EOL> for path_file in files : <EOL> year = str ( path_file [ - <NUM_LIT:8> : - <NUM_LIT:4> ] ) <EOL> if ( year != '<STR_LIT>' ) : <EOL> df_temp = pd . read_csv ( path_file , sep = '<STR_LIT:;>' ) <EOL> df_temp . rename ( columns = { '<STR_LIT>' : '<STR_LIT>' } , inplace = True ) <EOL> year_col = [ '<STR_LIT>' , '<STR_LIT>' ] <EOL> features_col = [ ] <EOL> for col in df_temp . columns [ <NUM_LIT:2> : ] : <EOL> year_col . append ( col + "<STR_LIT:_>" + year ) <EOL> features_col . append ( col + "<STR_LIT:_>" + year ) <EOL> features_col . append ( '<STR_LIT>' ) <EOL> df_temp . columns = year_col <EOL> df = pd . merge ( df , df_temp [ features_col ] , how = '<STR_LIT>' , on = '<STR_LIT>' ) <EOL> list_col = [ ] <EOL> for col in df . columns : <EOL> if "<STR_LIT>" in col . lower ( ) : <EOL> list_col . append ( col + "<STR_LIT>" ) <EOL> else : <EOL> list_col . append ( col ) <EOL> df . columns = list_col <EOL> df . to_csv ( '<STR_LIT>' , encoding = '<STR_LIT:utf-8>' , index = False ) </s>
