diff --git a/docs/_build/doctrees/auto/gsf.doctree b/docs/_build/doctrees/auto/gsf.doctree
index fc4d7cf..276a7c0 100644
Binary files a/docs/_build/doctrees/auto/gsf.doctree and b/docs/_build/doctrees/auto/gsf.doctree differ
diff --git a/docs/_build/doctrees/environment.pickle b/docs/_build/doctrees/environment.pickle
index 2f8aba6..59e769f 100644
Binary files a/docs/_build/doctrees/environment.pickle and b/docs/_build/doctrees/environment.pickle differ
diff --git a/docs/_build/doctrees/index.doctree b/docs/_build/doctrees/index.doctree
index a8a1409..bada2b0 100644
Binary files a/docs/_build/doctrees/index.doctree and b/docs/_build/doctrees/index.doctree differ
diff --git a/docs/_build/doctrees/parameters.doctree b/docs/_build/doctrees/parameters.doctree
index e8d8aaa..e995a1b 100644
Binary files a/docs/_build/doctrees/parameters.doctree and b/docs/_build/doctrees/parameters.doctree differ
diff --git a/docs/_build/doctrees/redshift_fitting.doctree b/docs/_build/doctrees/redshift_fitting.doctree
new file mode 100644
index 0000000..e8b181d
Binary files /dev/null and b/docs/_build/doctrees/redshift_fitting.doctree differ
diff --git a/docs/_build/doctrees/templates.doctree b/docs/_build/doctrees/templates.doctree
index e379130..d117e6e 100644
Binary files a/docs/_build/doctrees/templates.doctree and b/docs/_build/doctrees/templates.doctree differ
diff --git a/docs/_build/html/_sources/index.rst.txt b/docs/_build/html/_sources/index.rst.txt
index 248725a..e5d6ad3 100644
--- a/docs/_build/html/_sources/index.rst.txt
+++ b/docs/_build/html/_sources/index.rst.txt
@@ -19,6 +19,7 @@ gsf's documentation
fitting.rst
output.rst
prior.rst
+ redshift_fitting.rst
auto/modules
diff --git a/docs/_build/html/_sources/parameters.rst.txt b/docs/_build/html/_sources/parameters.rst.txt
index 6e13098..cb5b189 100644
--- a/docs/_build/html/_sources/parameters.rst.txt
+++ b/docs/_build/html/_sources/parameters.rst.txt
@@ -81,7 +81,7 @@ An example config file can be generated by executing the following command (TBD)
- Comma separated list for spectral files. Path is relative to DIR_EXTR.
* - MORP
- str
- - Profile shape, if grism spectra are provided. Will be used to convolve templates. "moffat", "gauss", or none.
+ - "moffat", "gauss", or none. Profile shape, if grism spectra are provided. Will be used to convolve templates.
* - MORP_FILE
- str
- Ascii file for morphology parameters.
@@ -136,6 +136,9 @@ An example config file can be generated by executing the following command (TBD)
* - AMIN
- str
- (Optional) Minimum value for amplitude, in normal logarithmic scale.
+ * - DUST_MODEL
+ - int
+ - Dust attenuation model (default 0). 0 for Calzetti. 1 for MW. 2 for LCM. 3 for SMC. 4 for Kriek & Conroy (2013).
* - AVMAX
- float
- (Optional) Maximum value for Av (dust attenuation in V-band), in mag.
@@ -170,8 +173,10 @@ An example config file can be generated by executing the following command (TBD)
-
-
+Read :ref:`Redshift Fitting Bases: The list of (possible) Mainbody attributes is given below: Find the best-fit redshift, before going into a big fit, through an interactive inspection.
-This module is effective only when spec data is provided.
Submodules
object
@@ -169,10 +170,14 @@
Submodules
SED model.
+Delta z in redshift search space
Lower limit range for redshift
@@ -183,12 +188,14 @@SN limit for data points. Those below the number will be cut from the fit.
Redshift fitting if only BB data. If False, returns nothing.
+Turn this True if Redshift fitting is requred for only BB data.
If True, line masking.
Dictionary that contains z (redshift grid) and chi2 (chi-square).
Exclude negative fluxes in spectrum.
+Spectral data must be provided to make this work.
@@ -206,7 +213,7 @@Saves a plot of z-distribution.
If true, this module returns figure ax.
@@ -216,7 +223,7 @@Main module of this script.
Used for error parameter.
@@ -243,21 +250,11 @@Fits input data with a prepared template library, to get a chi-min result.
-Array for initial values for metallicity.
-out, chidef, Zbest, xm_tmp, fm_tmp (if f_get_templates is set True).
-Read in observed data. Not model fluxes.
+Normalization coefficients for grism spectra. Cz0 for G102, Cz1 for G141.
Current redshift estimate.
@@ -269,7 +266,7 @@This module explores the redshift space to find the best redshift and probability distribution.
Dictionary that includes input data.
@@ -304,7 +301,7 @@The purpose of this module is to register/update the parameter attributes in Mainbody by visiting the configuration file.
RF Wavelength
+wavelength, at RF.
Flux for spectrum, in fnu
+Flux for spectrum, in fnu
Wavelength for spectrum, in AA (that matches filter response curve’s.)
+Wavelength for spectrum, in AA (that matches filter response curve’s.)
If True, read filter response curve.
+If True, read filter response curves and register those to MB.
Converts from Fnu to Flam, from mag zeropoint of m0set (to -48.6).
+current magzp.
+target magzp. The default, -48.6, is for flam (erg/s/cm2/lambda).
+Get RF UV (or any wavelength) flux density.
+Rest-frame wavelength, in AA.
Fnu
Convolved flux density. Not integrated sum.
+Flux density estimated over lmin:lmax. Not integrated sum.
Get initial parameters at various Z
get UV beta_lambda slope.
+in lambda
+in flambda
+Bases: object
The list of (possible) Func attributes is given below:
Gets an element template given a set of parameters. -Not necessarily the most efficient way, but easy to use.
+get_template(par, f_Alog: bool = True, nprec: int = 1, f_val: bool = False, lib_all: bool = False, f_nrd: bool = False, f_apply_dust: bool = True, f_IGM=True, deltaz_lim=0.1, f_neb=False, EBVratio: float = 2.27) +Makes model template for a given parameter set, par
.
library dictionary.
-Amplitude of the target template. Note that each template has Lbol = 1e10Lsun.
-Age, in Gyr.
-Dust attenuation, in mag.
-Metallicity, in log(Z/Zsun).
+Precision when redshift is refined.
Redshift.
+Apply dust attenuation to nebular emission.
If calculate bb photometry for the spectrum requested.
+E(B-V)_neb / E(B-V)_st. +Useful table in https://iopscience.iop.org/article/10.3847/1538-4357/aba35e/pdf
flux : float array. Flux in Fnu. -wavelength : float array. Wave in AA. -lcen, lflux : , if f_bb==True.
+Expect to explore nebular template or not.
This function is only used in plot_sed.py. +Common function for mebular and nonnebular temlates.
Loads dust template in obs range.
+E(B-V)_neb / E(B-V)_st. +Useful table in https://iopscience.iop.org/article/10.3847/1538-4357/aba35e/pdf
+This function is only used in plot_sed.py. +Common function for mebular and nonnebular temlates.
Load template in obs range.
+get total flux for a given set of parameter.
+contains parameters. Needs to include: [‘Z’,’A’]
+xx is OBSERVED wavelength at z=MB.zgal
+Load template in obs range. -But for weird template.
+get total flux for a given set of parameter.
+contains parameters
+Loads template in obs range.
+Loads dust template in obs range.
E(B-V)_neb / E(B-V)_st. -Useful table in https://iopscience.iop.org/article/10.3847/1538-4357/aba35e/pdf
+Load template in obs range.
+If 1, returns full spectra.
Makes model template with a given param set. -Also dust attenuation.
-Precision when redshift is refined.
+bool
If True, returns the original spectra.
lib : float array
Makes model template for a nebular emission.
-Precision when redshift is refined.
-Apply dust attenuation to nebular emission?
-E(B-V)_neb / E(B-V)_st. -Useful table in https://iopscience.iop.org/article/10.3847/1538-4357/aba35e/pdf
-Bases: object
Load dust template in obs range.
+Makes model template with a given param set. +Also dust attenuation.
+Precision when redshift is refined.
+Loads template in obs range.
-Loads template in obs range. -But for weird template.
-Loads template in obs range.
+Load dust template in obs range.
Makes model template with a given param set. -Also dust attenuation.
-Precision when redshift is refined.
-Loads template in obs range.
Makes model template with a given param set. -Also dust attenuation.
-Precision when redshift is refined.
-Apply IMG-attenuation of Dijikstra (2014). +https://www.cambridge.org/core/services/aop-cambridge-core/content/view/S1323358014000332
+Rest-frame wavelength, in AA.
+flux, in f_lambda.
+target redshift of IGM application
+Bubble size, in Mpc
+IGM attenuated flux.
+Voigt function
Very simplified model.
+HI column density of IGM at zin, in cm^-3.
+HI column density of IGM at zin, in cm^-2.
HI density in IGM.
+Get HI density by using Cen & Haiman 2000.
+HI density in IGM, in cm^-3
Rest-frame wavelength, in AA.
+flux, in f_lambda.
+zin : target redshift of IGM application
+IGM attenuated flux.
+gsf pipeline, which runs all steps.
If >0, the input templates get smoothing to delwave. @@ -953,7 +993,7 @@
Check library if it has a consistency setup as input file.
-True is no problem.
+flag : bool
Wavelength array, in AA.
Eq.34 of Draine & Li 2007. (default: 0.055) -~0.055 g / (ergs/s)
+Eq.34 of Draine & Li 2007. (default: 0.055g/(ergs/s))
+in cm.
DL : in cm.
Interpolated dust emission in Fnu of m0=25.0. In units of Fnu/Msun
umins = [‘0.10’, ‘0.15’, ‘0.20’, ‘0.30’, ‘0.40’, ‘0.50’, ‘0.70’, ‘0.80’, ‘1.00’, ‘1.20’, ‘1.50’, ‘2.00’, ‘2.50’, ‘3.00’, ‘4.00’, ‘5.00’, ‘7.00’, ‘8.00’, ‘10.0’, ‘12.0’, ‘15.0’, ‘20.0’, ‘25.0’] umaxs = [‘1e3’, ‘1e4’, ‘1e5’, ‘1e6’, ‘1e7’]
@@ -981,7 +1021,8 @@Make SPECTRA at given z and filter set.
+Make SPECTRA at given z and filter set. +Also, after v1.8, through this function library and data are register to the main class object, MB.
Configuration file.
SIMULATION of SPECTRA.
-wave_obs : -wave_temp : -flux_temp : -sn_obs
-frand, erand
+sn : float array
+frand : float array
+erand : float array
+This is for the preparation of default template, with FSPS, at z=0. Should be run before SED fitting.
Fit SFH with an n-order polynomial and reflect the residual to the prior. +Fit should be done in log-log space.
+If true, includes non-detection in likelihood calculation.
model as second output. For lnprob func.
Fit observed flux with a template to get redshift probability.
Initial value for redshift.
@@ -2276,6 +2323,31 @@redshift array for fit.
+observed values.
+template.
+output file
+