Skip to content

[MRG] Add example comparing PCR and PLS#17151

Merged
TomDLT merged 15 commits intoscikit-learn:masterfrom
NicolasHug:pcr_vs_pls_example
Aug 11, 2020
Merged

[MRG] Add example comparing PCR and PLS#17151
TomDLT merged 15 commits intoscikit-learn:masterfrom
NicolasHug:pcr_vs_pls_example

Conversation

@NicolasHug
Copy link
Copy Markdown
Member

@NicolasHug NicolasHug commented May 7, 2020

This is a simple example comparing Principal Component Regression and Partial Least Squares Regression. The goal is to illustrate how PLS can outperfor PCR when the target is strongly correlated with features that have a low variance (which are then dropped by PCA)

Can be merged before or after #17095 (reviews welcome there too!)

@NicolasHug NicolasHug changed the title [WIP] Add example comparing PCR and PLS [MRG] Add example comparing PCR and PLS May 7, 2020
@NicolasHug
Copy link
Copy Markdown
Member Author

@TomDLT @ogrisel @lorentzenchr @rth @cmarmo if you have time

Copy link
Copy Markdown
Contributor

@cmarmo cmarmo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@NicolasHug, thanks! Learned a lot!

@NicolasHug
Copy link
Copy Markdown
Member Author

Thanks all for your reviews so far. I have updated the example according to the comments. LMK what you think

Copy link
Copy Markdown
Member

@lorentzenchr lorentzenchr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (+1)
Maybe, I'm a bit pedantic about axis labeling. But it helps if you skim over the text and only look at the plots.

@NicolasHug
Copy link
Copy Markdown
Member Author

Maybe @ogrisel @glemaitre @rth can give this a quick look? It's been reviewed already!

Copy link
Copy Markdown
Member

@TomDLT TomDLT left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great example !

I would add a line in each axes of the third plot, showing the prediction of each model. This would emphasize that this third figure is conceptually different from the second one, and that the 1D projection is actually how the model is doing the predictions.

Copy link
Copy Markdown
Member

@TomDLT TomDLT left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More nitpicks.

Otherwise I think we can merge !

NicolasHug and others added 2 commits August 10, 2020 13:25
Co-authored-by: Tom Dupré la Tour <tom.dupre-la-tour@m4x.org>
@TomDLT TomDLT merged commit 25487f2 into scikit-learn:master Aug 11, 2020
@TomDLT
Copy link
Copy Markdown
Member

TomDLT commented Aug 11, 2020

Nice example !

jayzed82 pushed a commit to jayzed82/scikit-learn that referenced this pull request Oct 22, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants