Create output directory if required

etta-drone
Dan Howe 6 years ago
parent af6f51f331
commit 769a5d4275

@ -162,5 +162,11 @@ def update_survey_output(df, output_dir):
current_survey_col = current_profile.columns[-1] current_survey_col = current_profile.columns[-1]
master[current_survey_col] = current_profile[current_survey_col].values master[current_survey_col] = current_profile[current_survey_col].values
# Prepare output directory
try:
os.makedirs(output_dir)
except FileExistsError:
pass
# Export updated results # Export updated results
master.to_csv(csv_name, index=False) master.to_csv(csv_name, index=False)

Loading…
Cancel
Save