# %% scripts are superior to Jupyter Notebooks

Jupyter notebooks, while popular as an entry to data science, have many shortcomings. The drawbacks and dangers of over-reliance on Jupyter notebooks are best summarized in this 2018 talk by Joel Grus.

The percent format for Python scripts, denoted by # %%, is a great way to replace Jupyter notebooks. The percent format is supported by many editors, most notably VS Code. The official guide offers intuitive examples as introduction to the percent format and allows for a smooth transition from notebooks to scripts.

I have been using # %% since 2021 after a brief few weeks in Jupyter notebooks and never looked back.


You'll only receive email when they publish something new.

More from Spark Tseung
All posts