scikit-learn-contrib / scikit-learn-extra

scikit-learn contrib estimators
https://scikit-learn-extra.readthedocs.io
BSD 3-Clause "New" or "Revised" License
187 stars 42 forks source link

Using notebooks for examples #112

Closed TimotheeMathieu closed 3 years ago

TimotheeMathieu commented 3 years ago

Hello,

I am wondering whether it would be a good idea to use notebooks instead of scripts for the examples in the doc. For instance, I made this interactive notebook to illustrate robust algorithm and I find this notebook very intuitive and instructive. This may be a little difficult to integrate in the docs, maybe with binder ?

I also made some notebooks to illustrate the efficiency of robust estimators in classification and regression and I think it is much better to use notebook to be able to use markdown for the explanation instead of comments in the scripts. Non-interactive notebooks are quite nice I think and they can be viewed directly in github or with nbviewer.

What do you think ? Are there some specific reason why we don't use any noteobook for illustration ?

adrinjalali commented 3 years ago

Notebooks are notoriously hard to deal with when it comes to their changes, and git log, and git blame and git reviews. That's why we tend to use the scripts which are then compiled into notebooks as well and the user can use them as notebooks. If we want to allow users to look at the notebooks and run them on their own, binder is certainly a good idea, which means we don't have to put notebooks in the repo, but users can run the notebooks on binder if they want. You can have a look at how this is done in sklearn :)