Uploaded June 2022 | Updated November 2026, 3 hours ago
Visit brilliant.org/KeithGalli to get started learning STEM for free, and the first 200 people will get 20% off their annual premium subscription
In this video we walk through some of my favorite tips & tricks for doing data science with Jupyter Notebooks. Many of these tips have helped me become more efficient writing Python code for my data science projects.
Topics covered:
- Running bash commands from a jupyter notebook. You can use “!” in a code cell to run any terminal command that you want. You can also try using the “%” to execute magic lines. This includes some of the same bash commands that you might gravitate to as well as some Jupyter specific commands.
- The most useful shortcuts that I think you should know. Ctrl+enter to run a cell, shift+enter to run a cell and skip to the next, B to create new cells below, M to turn a cell to markdown, and several more. We will also look at find & replace in this section.
- Changing pandas default display settings (number of rows to display, columns, decimal points, etc.)
- Turning on OS alerts for running Jupyter Notebook cells. This is particularly useful if you have a long machine learning model training job going on and you want to know exactly when it finishes so that you can play around with the results.
- Creating slideshows within a Jupyter notebook!
Bonus topic:
- Changing your Jupyter Notebook theme! Monokai is a good one to use if you like dark-themes
Source code:
github.com/KeithGalli/Data-Science-Tips/tree/master/jupyter-notebook-tips
If you have any questions about these tips & tricks, or if you have additional recommendations, please let me know in the comments!
I hope you enjoyed this video! Please subscribe & give it a like if you did.
Resources:
- towardsdatascience.com/8-commonly-used-pandas-display-options-you-should-know-a832365efa95
Learn more about magic commands "%": ipython.readthedocs.io/en/stable/interactive/magics.html
-------------------------
Follow me on social media!
Instagram | instagram.com/keithgalli
Twitter | twitter.com/keithgalli
TikTok | tiktok.com/@keithgalli
-------------------------
Song at the end
good morning by Amine Maxwell soundcloud.com/aminemaxwell
Creative Commons — Attribution 3.0 Unported — CC BY 3.0
Free Download / Stream: bit.ly/2vpruoY
Music promoted by Audio Library youtu.be/SQWFdnbzlgI
-------------------------
If you are curious to learn how I make my tutorials, check out this video: youtu.be/LEO4igyXbLs
Practice your Python Pandas data science skills with problems on StrataScratch!
stratascratch.com/?via=keith
Join the Python Army to get access to perks!
YouTube - youtube.com/channel/UCq6XkhO5SZ66N04IcPbqNcw/join
Patreon - patreon.com/keithgalli
*I use affiliate links on the products that I recommend. I may earn a purchase commission or a referral bonus from the usage of these links.
This video was sponsored by Brilliant.org
-------------------------
Video timeline!
0:00 - Introduction & video overview
0:25 - Shoutout to this video’s sponsor, Brilliant.org!
2:11 - 1. Running terminal commands such as “pip” directly in a notebook
5:17 - Magic lines in Jupyter
6:11- 2. Shortcuts that you need to know for Jupyter!
9:25 - 3. Changing default Pandas options to improve results display
14:00 - 4. Setting up notifications for when a cell finishes execution
18:08 - 5. Creating slideshows from a IPython notebook!
23:00 - Conclusion (and link to bonus tip!)
Visit brilliant.org/KeithGalli to get started learning STEM for free, and the first 200 people will get 20% off their annual premium subscription
In this video we walk through some of my favorite tips & tricks for doing data science with Jupyter Notebooks. Many of these tips have helped me become more efficient writing Python code for my data science projects.
Topics covered:
- Running bash commands from a jupyter notebook. You can use “!” in a code cell to run any terminal command that you want. You can also try using the “%” to execute magic lines. This includes some of the same bash commands that you might gravitate to as well as some Jupyter specific commands.
- The most useful shortcuts that I think you should know. Ctrl+enter to run a cell, shift+enter to run a cell and skip to the next, B to create new cells below, M to turn a cell to markdown, and several more. We will also look at find & replace in this section.
- Changing pandas default display settings (number of rows to display, columns, decimal points, etc.)
- Turning on OS alerts for running Jupyter Notebook cells. This is particularly useful if you have a long machine learning model training job going on and you want to know exactly when it finishes so that you can play around with the results.
- Creating slideshows within a Jupyter notebook!
Bonus topic:
- Changing your Jupyter Notebook theme! Monokai is a good one to use if you like dark-themes
Source code:
github.com/KeithGalli/Data-Science-Tips/tree/master/jupyter-notebook-tips
If you have any questions about these tips & tricks, or if you have additional recommendations, please let me know in the comments!
I hope you enjoyed this video! Please subscribe & give it a like if you did.
Resources:
- towardsdatascience.com/8-commonly-used-pandas-display-options-you-should-know-a832365efa95
Learn more about magic commands "%": ipython.readthedocs.io/en/stable/interactive/magics.html
-------------------------
Follow me on social media!
Instagram | instagram.com/keithgalli
Twitter | twitter.com/keithgalli
TikTok | tiktok.com/@keithgalli
-------------------------
Song at the end
good morning by Amine Maxwell soundcloud.com/aminemaxwell
Creative Commons — Attribution 3.0 Unported — CC BY 3.0
Free Download / Stream: bit.ly/2vpruoY
Music promoted by Audio Library youtu.be/SQWFdnbzlgI
-------------------------
If you are curious to learn how I make my tutorials, check out this video: youtu.be/LEO4igyXbLs
Practice your Python Pandas data science skills with problems on StrataScratch!
stratascratch.com/?via=keith
Join the Python Army to get access to perks!
YouTube - youtube.com/channel/UCq6XkhO5SZ66N04IcPbqNcw/join
Patreon - patreon.com/keithgalli
*I use affiliate links on the products that I recommend. I may earn a purchase commission or a referral bonus from the usage of these links.
This video was sponsored by Brilliant.org
-------------------------
Video timeline!
0:00 - Introduction & video overview
0:25 - Shoutout to this video’s sponsor, Brilliant.org!
2:11 - 1. Running terminal commands such as “pip” directly in a notebook
5:17 - Magic lines in Jupyter
6:11- 2. Shortcuts that you need to know for Jupyter!
9:25 - 3. Changing default Pandas options to improve results display
14:00 - 4. Setting up notifications for when a cell finishes execution
18:08 - 5. Creating slideshows from a IPython notebook!
23:00 - Conclusion (and link to bonus tip!)




![Solving Leetcode Coding Interview Questions in Python!
Lets do some leetcode coding problems live! Join Saturday at 11am EST for about 2-3 hours of Python problems. Will plan to give some advice on how to strengthen your coding interview skills more generally as well. Hope to see you there!
https://leetcode.com/explore/featured/card/top-interview-questions-easy/
Learn data skills with hands-on exercises & tutorials at Datacamp!
https://datacamp.pxf.io/c/3588040/1012793/13294
Video Timeline!
0:00 - Fixing Live Stream Settings
2:38 - Introduction & what were doing today
4:10 - [Leetcode 412] Fizz Buzz string manipulation problem
22:04 - [Leetcode 189] Rotate Array
46:39 - [Leetcode 217] Contains Duplicate list problem
1:01:44 - [Leetcode 125] Valid Palindrome string problem
1:17:37 - [Leetcode 237] Delete Node in a Linked List (watch my brain not function properly!!!)
2:06:19 - [Leetcode 136] Single Number (trickier problem than it might first seem!)
2:28:52 - [Leetcode 104] Maximum Depth of a Binary Tree
2:47:35 - [Leetcode 36] Valid Sudoku (good function design problem)
Follow me on social media!
Instagram | https://www.instagram.com/keithgalli/
Twitter | https://twitter.com/keithgalli
TikTok | https://tiktok.com/@keithgalli
Practice your Python Pandas data science skills with problems on StrataScratch!
https://stratascratch.com/?via=keith
Join the Python Army to get access to perks!
YouTube - https://www.youtube.com/channel/UCq6XkhO5SZ66N04IcPbqNcw/join
Patreon - https://www.patreon.com/keithgalli
*I use affiliate links on the products that I recommend. I may earn a purchase commission or a referral bonus from the usage of these links. Solving Leetcode Coding Interview Questions in Python!](https://i.ytimg.com/vi/btdna5esLsI/mqdefault.jpg)





