Finance Train LogoFinance Train
Learning LibraryTemplatesBlog
Data Science Bundle
Finance TrainFinance Train
Learning LibraryTemplatesBlog
Data Science Bundle

Getting Started with Jupyter Notebooks

January 3, 2026
5 min read

Learn to use Jupyter notebooks for interactive coding, data analysis, and sharing your work.

Getting Started with Jupyter Notebooks

Jupyter notebooks are the standard tool for interactive data science work. They let you write code, see results immediately, add explanations, and share your analysis - all in one document. If you're learning Python or R for data work, you'll spend a lot of time in Jupyter.

What is a Jupyter Notebook?

A Jupyter notebook is an interactive document that combines:

  • Code cells - Write and run Python or R code
  • Output - See results, charts, and tables inline
  • Markdown cells - Add formatted text, explanations, and documentation
  • Rich media - Display images, HTML, and interactive widgets

The name "Jupyter" comes from Julia, Python, and R - the three languages it originally supported. Today it works with dozens of languages, but Python is most common.

Why Use Notebooks?

Exploratory analysis. When you're investigating data, you want to try things quickly and see results. Notebooks let you run code in chunks, inspect outputs, and iterate fast.

Documentation built-in. You can explain your thinking alongside your code. This makes notebooks great for sharing analysis with colleagues who want to understand your approach.

Visualization inline. Charts and plots appear right below the code that generated them. No switching between windows.

Reproducibility. A notebook captures your entire analysis workflow. Others can run it and get the same results.

Installing Jupyter

Option 1: With Anaconda (Recommended for beginners)

Anaconda includes Jupyter, Python, and common data science packages:

  1. Download Anaconda from anaconda.com
  2. Run the installer
  3. Open Anaconda Navigator and launch Jupyter Notebook

Option 2: With pip

If you already have Python installed:

pip install jupyter

Then run:

jupyter notebook

Option 3: JupyterLab

JupyterLab is the newer interface with more features:

1pip install jupyterlab
2jupyter lab
3
bash

The Interface

When you launch Jupyter, it opens in your web browser. You'll see:

File browser - Navigate your folders and open notebooks (.ipynb files)

Notebook view - The main editing area with cells

Toolbar - Buttons for common actions (run, stop, save)

Kernel indicator - Shows whether code is running

Working with Cells

Notebooks are made of cells. Each cell is either:

Code Cells

Type Python code and press Shift+Enter to run:

1import pandas as pd
2df = pd.read_csv('data.csv')
3df.head()
4
python

The output appears directly below the cell.

Markdown Cells

Write formatted text using Markdown syntax:

1## Analysis Summary
2
3This section explores the **key findings** from our data:
4
5- Finding 1
6- Finding 2
7- Finding 3
8
markdown

Press Shift+Enter to render the formatted text.

Essential Keyboard Shortcuts

These will speed up your work significantly:

ActionShortcut
Run cellShift + Enter
Run cell, stay in placeCtrl + Enter
Insert cell belowB (in command mode)
Insert cell aboveA (in command mode)
Delete cellDD (in command mode)
Switch to MarkdownM (in command mode)
Switch to CodeY (in command mode)
Enter command modeEsc
Enter edit modeEnter

Command mode (blue cell border): Navigate and manipulate cells Edit mode (green cell border): Type in a cell

Best Practices

Keep cells focused

Each cell should do one thing. This makes debugging easier and helps readers follow your logic.

1# Good: One operation per cell
2df = pd.read_csv('sales.csv')
3
python
df['total'] = df['quantity'] * df['price'] df.groupby('region')['total'].sum()

Add Markdown explanations

Don't just show code - explain what you're doing and why:

1## Data Cleaning
2
3The raw data has several issues we need to address:
4- Missing values in the 'region' column
5- Duplicate transaction IDs
6- Negative quantities (likely returns)
7
markdown

Restart and run all

Before sharing, restart the kernel and run all cells from top to bottom. This catches issues where cells depend on deleted code or out-of-order execution.

Kernel > Restart & Run All

Use meaningful names

Name your notebooks descriptively:

  • Good: 2024-01-sales-analysis.ipynb
  • Bad: Untitled.ipynb

Common Patterns

Data exploration workflow

1# Load data
2import pandas as pd
3df = pd.read_csv('data.csv')
4
5# Quick look
6df.head()
7
python
1# Shape and types
2print(f"Rows: {len(df)}, Columns: {len(df.columns)}")
3df.dtypes
4
python
1# Summary statistics
2df.describe()
3
python
1# Check for missing values
2df.isnull().sum()
3
python

Visualization

1import matplotlib.pyplot as plt
2
3# Enable inline plots
4%matplotlib inline
5
6# Create a chart
7df['category'].value_counts().plot(kind='bar')
8plt.title('Sales by Category')
9plt.show()
10
python

Suppress output

Add a semicolon to prevent output:

1fig, ax = plt.subplots(figsize=(10, 6));  # No extra output
2
python

Notebooks vs Scripts

Use notebooks for:

  • Exploratory analysis
  • Learning and experimentation
  • Sharing analysis with explanations
  • Quick prototyping

Use scripts (.py files) for:

  • Production code
  • Reusable functions and modules
  • Automation
  • Version control (notebooks don't diff well)

Many data scientists prototype in notebooks, then move finalized code to scripts.

JupyterLab vs Classic Notebook

Classic Notebook - Simpler, one notebook at a time, lighter weight

JupyterLab - Multiple tabs, file browser, terminal, more IDE-like

Both work with the same .ipynb files. JupyterLab is the direction Jupyter is heading, but classic notebooks are still widely used.

Next Steps

  1. Install Jupyter using one of the methods above
  2. Create a new notebook and run some basic Python
  3. Load a dataset with pandas and explore it
  4. Add Markdown to document your analysis
  5. Practice shortcuts until they're automatic

Notebooks are a tool - the more you use them, the more natural they become. Start simple, and you'll develop your own workflow over time.

Learning Library

Practical resources on data science, machine learning, and AI for finance professionals.

Browse Library
Mini Roadmap - Data Science for Finance
Free Download

Mini Roadmap: Data Science for Finance

A step-by-step guide covering Python, SQL, analytics, and finance applications.

Finance Train

Learn data science and AI skills for finance through practical courses and tutorials.

Learn

  • Learning Library
  • Course Directory
  • Blog

Resources

  • Templates & Downloads
  • Tools
  • Tables
  • Calculators

Company

  • About
  • Contact
  • Privacy
  • Terms

© 2026 Finance Train. All rights reserved.