8000 DOC: use notebook-style for plot_logistic_path.py by alexanmv · Pull Request #22536 · scikit-learn/scikit-learn · GitHub
[go: up one dir, main page]

Skip to content

DOC: use notebook-style for plot_logistic_path.py #22536

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Feb 22, 2022

Conversation

alexanmv
Copy link
Contributor

making the '# ####' comment line to '# %%' type and making a header for demo path functions. Also made a header with '# %%' type for author and license. Thought also about making author and license into note style but header seemed better.

Fix issue for plot_logistic_path/PRs

For Issue [Fix notebook-style examples]
#22406
examples/linear_model/plot_logistic_path.py

What does this implement/fix? Explain your changes.

making the '# ####' comment line to '# %%' type and making a header for demo path functions. Also made a header with '# %%' type for author and license. Thought also about making author and license into note style but header seemed better.

Any other comments?

making the '# ####' comment line to '# %%' type and making a header for demo path functions. Also made a header with '# %%' type for author and license. Thought also about making author and license into note style but header seemed better.
@lesteve lesteve mentioned this pull request Feb 21, 2022
47 tasks
@lesteve lesteve added the Quick Review For PRs that are quick to review label Feb 22, 2022
@lesteve
Copy link
Member
lesteve commented Feb 22, 2022

Thanks a lot for your PR!

In my last commit I changed a few things:

  • Author and License don't need to have their own section so I put them back as comments
  • I broke the example down into more sections
  • I moved the imports closer to where they are needed, this is closer to what you would write in a notebook (even if not considered good coding style by pycodestyle)
  • remove the time.time() and print statement, they do no seem that useful (even if you run the example as a script it takes ~2s)

@lesteve lesteve changed the title Update plot_logistic_path.py DOC: use notebook-style for plot_logistic_path.py Feb 22, 2022
@lesteve lesteve merged commit 46f15a0 into scikit-learn:main Feb 22, 2022
@lesteve
Copy link
Member
lesteve commented Feb 22, 2022

Merging, thanks a lot!

@alexanmv
Copy link
Contributor Author

Merging, thanks a lot
i thank you for merging my branch and thank you for explaining the extra changes you made. They will be very useful for the next contribution.

thomasjpfan pushed a commit to thomasjpfan/scikit-learn that referenced this pull request Mar 1, 2022
Co-authored-by: Loïc Estève <loic.esteve@ymail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Quick Review For PRs that are quick to review
Projects
None yet
3D6B
Development

Successfully merging this pull request may close these issues.

2 participants
0