Skip to content

PolynomialFeatures constructor is called with the wrong degree #8

@covuworie

Description

@covuworie

I have seen a bug in the section Cross Validation: For Selecting Polynomial Model Degree of Lecture_6_Notebook.ipynb. The degree d is incorrectly used in the PolynomialFeatures constructor. This has a value of 19 which is the last index of the previous loop. The intention is to use the degree with the best cross-validation score so the code should read:

gen_poly_terms = PolynomialFeatures(degree=best_degree, interaction_only=False)

PS: Likewise, I have not submitted a pull request for this as you may not want the output produced from my notebook.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions