Q3 Box-plot

Excuse me, this is about getting information about the weight (absolute value) to identify the two most important characteristics that the ridge regressor uses, but when I run:

coefs = [estimator [-1] .coef_ for estimator in cv_results ["estimator"]]
coefs = pd.DataFrame (coefs, columns = numeric_features)
coefs.describe (). loc [["min", "max"]]

First:
the graph shows only the maximum and minimum values and does not show the characteristic “GrLivArea”
when I try:

coefs.describe ()

it shows more information (average, standard, etc.) but I don’t see “GrLivArea”.
So I ask what criteria should be used and how can I show all the features (how can I use the box plot).
Also [-1], in [estimator [-1] .coef_ for estimator in cv_results [“estimator”]], is the last step? that is to say count from the end? Thank you

Since coefs is a dataframe, you could select the column of interest:

coefs[["GrLivArea"]].describe()

You can plot using a boxplot wiht

coefs.plot.box()

Yes exactly. This is to get the classifier/regressor that has the attribute coef_.

1 Like