graphinglib.Histogram.from_fit_residuals#
- classmethod Histogram.from_fit_residuals(fit: Fit, number_of_bins: int, label: str | None = None, face_color: str = 'default', edge_color: str = 'default', hist_type: str = 'default', alpha: int | Literal['default'] = 'default', line_width: int | Literal['default'] = 'default', normalize: bool | Literal['default'] = 'default', show_params: bool | Literal['default'] = 'default') Self [source]#
Calculates the residuals of a fit and plots them as a histogram.
- Parameters:
- fitFit
The fit from which the residuals are to be calculated.
- number_of_binsint
Number of bins to be used in the histogram.
- labelstr, optional
Label to be displayed in the legend.
- face_colorstr
Face color of the histogram. Default depends on the
figure_style
configuration.- edge_colorstr
Edge color of the histogram. Default depends on the
figure_style
configuration.- hist_typestr
Type of the histogram. Can be “bar”, “barstacked”, “step”, “stepfilled”. Default depends on the
figure_style
configuration.- alphafloat
Transparency of the histogram. Default depends on the
figure_style
configuration.- line_widthfloat
Width of the histogram edge. Default depends on the
figure_style
configuration.- normalizebool
Whether or not to normalize the histogram. Default depends on the
figure_style
configuration.- show_pdfstr
Whether or not to show the probability density function. Can be “normal” or “gaussian”. Default depends on the
figure_style
configuration.- show_paramsbool
Whether or not to show the mean and standard deviation of the data. Default depends on the
figure_style
configuration.
- Returns:
- A
Histogram
object created from the residuals of a fit.
- A