Commit 50794ba4 authored by Médéric Boquien's avatar Médéric Boquien

It is now possible to plot the best fit obtained in redshifting mode.

parent 2d3a1d8a
......@@ -19,6 +19,7 @@
- The plot of the PDF could not be generated for physical properties estimated in log (Médéric Boquien)
- We do not attempt anymore to estimate the physical properties of galaxies with insanely large χ² that lead to an underflow in the computation of the likelihood. (Médéric Boquien)
- The best fit is now plotted at the exact redshift rather than at the rounded redshift. (Médéric Boquien)
- It is now possible to plot the best fit obtained in redshifting mode. (Médéric Boquien)
### Optimised
- The estimation of the physical properties is made a bit faster when all the models are valid. (Médéric Boquien)
......
......@@ -164,7 +164,10 @@ def _sed_worker(obs, mod, filters, sed_type, nologo):
obs_fluxes_err = np.array([obs[filt+'_err']
for filt in filters.keys()])
mod_fluxes = np.array([mod["best."+filt] for filt in filters.keys()])
z = obs['redshift']
if obs['redshift'] >= 0:
z = obs['redshift']
else: # Redshift mode
z = mod['best.universe.redshift']
DL = mod['best.universe.luminosity_distance']
if sed_type == 'lum':
......@@ -342,8 +345,7 @@ def _sed_worker(obs, mod, filters, sed_type, nologo):
plt.setp(ax1.get_xticklabels(), visible=False)
plt.setp(ax1.get_yticklabels()[1], visible=False)
figure.suptitle("Best model for {} at z = {}. Reduced $\chi^2$={}".
format(obs['id'], np.round(obs['redshift'],
decimals=3),
format(obs['id'], np.round(z, decimals=3),
np.round(mod['best.reduced_chi_square'],
decimals=2)))
if nologo is False:
......
Markdown is supported
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