Commit 0db151be authored by Cecilia Nievas's avatar Cecilia Nievas
Browse files

Created area_per_dwelling_sqm from area_per_building_sqm column (Com, Ind)

parent 5bf0113d
......@@ -89,6 +89,8 @@ def get_admin_level_definition(country_name, path, output_dfs=False, full_files=
elif complete_col_list_types[j]== 'float':
if col=='dwellings':
aux_df[col]= aux_df['buildings'].values # one dwelling per building assumed when no dwellings column available (the assumption is consistent with the Com and Ind models, for Res the dwellings column exists)
elif col=='area_per_dwelling_sqm':
aux_df[col]= aux_df['area_per_building_sqm'].values # one dwelling per building assumed
aux_df[col]= np.zeros([aux_df.shape[0]])
out_dataframes[case]= aux_df
......@@ -129,8 +131,8 @@ def get_complete_list_of_columns(full_files_flag):
id_X and name_X are ommited, and so are longitude and latitude (we cannot "fill in" these data).
if full_files_flag:
out_list= ['settlement_type','occupancy_type','dwellings']
out_types= ['str','str','float']
out_list= ['settlement_type','occupancy_type','dwellings','area_per_dwelling_sqm']
out_types= ['str','str','float','float']
else: # I expect this function to be irrelevant for the case of the OpenQuake CSV files
out_list= []
out_types= []
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment