coefficients#
- EstimatorReport.inspection.coefficients()[source]#
Retrieve the coefficients of a linear model, including the intercept.
- Returns:
CoefficientsDisplayThe feature importance display containing model coefficients and intercept.
Examples
>>> from sklearn.datasets import load_diabetes >>> from sklearn.linear_model import Ridge >>> from skore import evaluate >>> X, y = load_diabetes(return_X_y=True) >>> regressor = Ridge() >>> report = evaluate(regressor, X, y, splitter=0.2) >>> display = report.inspection.coefficients() >>> display.frame() feature coefficient 0 Intercept 151.9... 1 Feature #0 21.3... 2 Feature #1 -72.9... 3 Feature #2 301.3... 4 Feature #3 177.4... 5 Feature #4 2.8... 6 Feature #5 -35.2... 7 Feature #6 -155.5... 8 Feature #7 118.3... 9 Feature #8 257.3... 10 Feature #9 102.2... >>> display.plot() # shows plot