make_plots¶
-
mastml.plots.
make_plots
(plots, y_true, y_pred, groups, dataset_stdev, metrics, model, residuals, model_errors, has_model_errors, savepath, data_type, show_figure=False, recalibrate_errors=False, model_errors_cal=None, splits_summary=False)[source]¶ Helper function to make collections of different types of plots after a single or multiple data splits are evaluated.
- Args:
plots: (list of str), list denoting which types of plots to make. Viable entries are “Scatter”, “Histogram”, “Error”
y_true: (pd.Series), series containing the true y data
y_pred: (pd.Series), series containing the predicted y data
groups: (list), list denoting the group label for each data point
dataset_stdev: (float), the dataset standard deviation
metrics: (list of str), list denoting the metric names to evaluate. See mastml.metrics.Metrics.metrics_zoo_ for full list
model: (mastml.models object), a MAST-ML model object, e.g. SklearnModel or EnsembleModel
residuals: (pd.Series), series containing the residuals (true model errors)
model_errors: (pd.Series), series containing the as-obtained uncalibrated model errors
has_model_errors: (bool), whether the model type used can be subject to UQ and thus have model errors calculated
savepath: (str), string denoting the path to save output to
data_type: (str), string denoting the data type analyzed, e.g. train, test, leftout
show_figure: (bool), whether or not the generated figure is output to the notebook screen (default False)
recalibrate_errors: (bool), whether or not the model errors have been recalibrated (default False)
model_errors_cal: (pd.Series), series containing the calibrated predicted model errors
splits_summary: (bool), whether or not the data used in the plots comes from a collection of many splits (default False), False denotes a single split folder
- Returns:
- None.