Wrap-up quiz 4 - Quiestion 7

I tried use a plot as we did in the lecture Regularization of linear regression model, plotting each value of alpha using log scale.

mse_alphas_6 = est[-1].cv_values_.mean(axis=0)
              for est in cv_results["estimator"]]
cv_alphas_6 = pd.DataFrame(mse_alphas_6, columns=alphas)
cv_alphas_6

cv_alphas_6.mean(axis=0).plot(marker="+")
plt.ylabel("Mean squared error\n (lower is better)")
plt.xlabel("alpha")
plt.xscale('log')
_ = plt.title("Error obtained by cross-validation")

How get a better vision for better one decision, any hint?

You can use a swarmplot seaborn.swarmplot — seaborn 0.11.1 documentation
or a histogram. The idea here is to check if all the alpha values are stable or if they vary by a lot.