zphot_zspec¶
- eazy.utils.zphot_zspec(zphot, zspec, zlimits=None, zmin=0, zmax=4, axes=None, figsize=[6, 7], minor=0.5, skip=2, selection=None, catastrophic_limit=0.15, title=None, min_zphot=0.02, alpha=0.2, extra_xlabel='', extra_ylabel='', xlabel='$z_\\mathrm{spec}$', ylabel='$z_\\mathrm{phot}$', label_pos=(0.05, 0.95), label_kwargs={'fontsize': 10, 'ha': 'left', 'va': 'top'}, label_prefix='', format_axes=True, color='k', point_label=None, **kwargs)[source]¶
Make zphot_zspec plot scaled by log(1+z) and show uncertainties
- Parameters:
- zphotarray-like
Redshift on dependent axis
- zspecarray-like
Redshift on independent axis
- zlimits(N, 2) array
Redshifts to use for photo-z errorbars, e.g. from
pz_percentiles
, whereN
is the number of objects as inzphot
andzspec
- zmin, zmaxfloat
Plot limits
- axes
matplotlib
axes, None If specified, overplot in existing axes rather than generating a new plot. For example, run the function once to generate the figure and then plot different points onto the existing axes:
>>> fig = eazy.utils.zphot_spec(zphot, zspec, selection=sample1) >>> _ = eazy.utils.zphot_spec(zphot, zspec, selection=sample2, >>> axes=fig.axes, color='b')
- figsizelist
Figure canvas dimensions
- minorfloat
Axis tick interval
- skipint
Put axis labels every
skip
ticks- selectionarray-like
Subsample selection (boolean or indices) applied as
zphot[selection]
- catastrophic_limitfloat
Limit to define “catastrophic” failures, which is used for computing precision / outlier statistics printed on the plot
- titlestr
Title to add to the plot axes
- Returns:
- fig
matplotlib.figure.Figure
Figure object
- fig