Hacker News new | ask | show | jobs
by 746F7475 3830 days ago
So what is the usual usecase for these Jupyter notebooks? I see everyone praising them, but I still don't really know a good use case. I thought about using it as notebook for work stuff, but I don't want to run something in command line and then in browser to make a simple note when I can just open vim and make a quick note
5 comments

Recent use for me:

Semi-technical boss comes to me and says "Hey look! I wrote this cool SQL query to figure out what time of day our service is being used most. Can you turn it into a heatmap?"

And of course you know if you do something like this once, you will be asked to do it again, until pretty soon you will be expected to do it automatically every week or something.

So: Jupyter notebook to the rescue. Query the DB, wave hands a few times, produce a heatmap (total lines of python: about 10). Then give boss the notebook and tell him if he wants to update or modify, have at it, here's where your query is.

I never have to deal with it again, it's self-documenting and transparently future-friendly (anybody with an ounce of sense can edit it) and it looks all mathematica and stuff. Case closed.

For me, it's nice for interactive code and visualization development. Particularly when parts of a script are slow running, being able to do it once and then iterate on a dependent part in a notebook cell saves a lot of time.

Once I'm done, I can document it inline with markdown and latex.

Exploratory data analysis. I may need to play around with loading data from a format I'm unfamiliar with, then do some basic summaries or information gathering about the data. This makes it straightforward to iterate on this type of stuff (instead of having to use command line REPL and press up arrows alot to re-run code sections without re-typing or pasting code). It's straightforward to share with someone familiar with Jupyter, and to a lesser extent with others who just need to look through the analysis results or code shown by the notebook. Though to be honest, when there isn't something about the analysis Python makes simpler, I find R with RStudio to have more flexibility for this kind of stuff, personally.
For me: anything involving data (data scraping, exploratory data analysis, plotting, testing various machine learning techniques, etc); here short feedback loop is crucial + it's great to have plots in place.

Also (a bit) for playing around with new libraries / databases etc. (Much better than both Python scripts (need to be rerun from scratch) and Python shell.)

Verification. If you compare traditional data analysis in Excel and such, it is much easier to verify what is going on in a notebook than it is in multitudes of Excel sheets. Easy calculation views, graphs, tables, etc.