Skip to content

Commit

Permalink
analysis.attenuation.compute_EBV: Use filename_dict for input files (…
Browse files Browse the repository at this point in the history
…iss #10)
  • Loading branch information
astrochun committed May 30, 2020
1 parent cd02279 commit bc80a0b
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Metallicity_Stack_Commons/analysis/attenuation.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
from os.path import join

from .. import k_dict, line_name_short
from ..column_names import filename_dict

HgHb_CaseB = 0.468 # Hg/Hb ratio for zero reddening
HaHb_CaseB = 2.86 # Ha/Hb ratio for zero reddening
Expand All @@ -15,7 +16,7 @@
k_HGAMMA = k_dict[HG]


def compute_EBV(fitspath, combine_asc):
def compute_EBV(fitspath):
"""
Purpose:
Determines E(B-V) from Hg/Hb flux ratio
Expand All @@ -24,6 +25,10 @@ def compute_EBV(fitspath, combine_asc):
:param combine_asc: Astropy table containing emission-line flux
"""

combine_file = join(fitspath, filename_dict['bin_fit_rev'])
print("Reading : " + combine_file)
combine_asc = asc.read(combine_file)

ID = combine_asc['ID']
HBETA = combine_asc[HB+'_Flux_Observed'].data
HGAMMA = combine_asc[HG+'_Flux_Observed'].data
Expand Down

0 comments on commit bc80a0b

Please sign in to comment.