Daily Dose of Data Science

Share this post

The Coolest Jupyter Notebook Hack

www.blog.dailydoseofds.com

The Coolest Jupyter Notebook Hack

Three ways to retrieve a cell's output in Jupyter.

Avi Chawla
Jan 8, 2023
4
Share

Have you ever forgotten to assign the results to a variable in Jupyter? Rather than recomputing the result by rerunning the cell, here are three ways to retrieve the output.

1️⃣ Use the underscore followed by the output-cell-index.

2️⃣/3️⃣ Use the 𝐎𝐮𝐭 or _𝐨𝐡 dict and specify the output-cell-index as the key.

Share this post on LinkedIn: Post Link.

Thanks for reading Daily Dose of Data Science! Subscribe for free to learn something new and insightful about Python and Data Science every day. Also, get a Free Data Science PDF (250+ pages) with 200+ tips.


Find the code for my tips here: GitHub.

I like to explore, experiment and write about data science concepts and tools. You can read my articles on Medium. Also, you can connect with me on LinkedIn.

4
Share
Previous
Next
Comments
Top
New
Community

No posts

Ready for more?

© 2023 Avi Chawla
Privacy ∙ Terms ∙ Collection notice
Start WritingGet the app
Substack is the home for great writing