Skip to content

Commit

Permalink
error_prop.fluxes_derived_prop: Update prop_tab0 and write binned der…
Browse files Browse the repository at this point in the history
…ived properties table (iss #5)
  • Loading branch information
astrochun committed Mar 28, 2020
1 parent 4da4a0f commit 0f4f8c2
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions Metallicity_Stack_Commons/error_prop.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,17 @@ def fluxes_derived_prop(path, binned_data=True):
derived_prop_error_dict[names0+'_lowhigh_error'] = err_prop
derived_prop_peak_dict[names0+'_peak'] = peak_prop

prop_tab0[names0][detect_idx] = peak_prop

# Edit ASCII Table
new_prop_file = join(path, filename_dict['bin_derived_prop_rev'])

if exists(new_prop_file):
print("Overwriting: "+new_prop_file)
else:
print("Writing: "+new_prop_file)
asc.write(prop_tab0, new_prop_file, overwrite=True, format='fixed_width_two_line')

npz_files = [npz_filename_dict['der_prop_pdf'],
npz_filename_dict['der_prop_errors'],
npz_filename_dict['der_prop_peak']]
Expand Down

0 comments on commit 0f4f8c2

Please sign in to comment.