Chapter2 - Python and Jupyter Notebook
Chapter2 - Python and Jupyter Notebook
OCTOBER 2022
OVERVIEW
Learning objectives
1 Introduction to Python
Outline:
1 Introduction to Python
What is Python?
What is Python Used For?
Why Python?
2 Jupyter Notebook: How to Use?
What is Jupyter Notebook?
Installation
Creating Your First Notebook
Markdown
Sharing Your Notebooks
Reference: (https://www.dataquest.io/blog/jupyter-notebook-tutorial/ )
1. Introduction to Python
1.1 What is Python?
It is a programming language.
Created in 1991 by Dutch programmer Guido Van Rossum.
It aims to limit code blocks and less busy appearance.
It can be placed as a fourth-generation programming language.
(Source: https://codeinstitute.net/global/blog/what-is-python-used-for/ )
1. Introduction to Python
1.1 What is Python?
1. Introduction to Python
1.2 What is Python Used For?
1. Introduction to Python
1.3 Why Python?
(Source: https://www.kdnuggets.com/2020/06/data-science-tools-
popularity-animated.html )
1. Introduction to Python
1.3 Why Python?
1. Introduction to Python
1.3 Why Python?
Running Jupyter
Click the “New” drop-down button in the top-right and select “Python
3”:
1st example
Type print(’Hello World!’) into the cell and click the run button
Notebook Run Button in the toolbar above or press Ctrl + Enter.
2nd example
Type the following command and press Ctrl + Enter.
Program 8:
Example:
Tasks in Pairs
1 Create a list of your favorite fruits and print each fruit in the list
2 Write a program that prints the first 10 even numbers.
3 Write a program that checks whether a number is positive, negative,
or zero.
4 Generate a scatter plot using randomly generated data points.
5 Generate a histogram plot to visualize the distribution of a dataset.
6 Implement a simple linear regression model using a small dataset.
7 Create a heatmap to visualize the correlation between different
variables.
8 Create multiple plots within a single figure using subplots.
Submit your Jupyter file or pdf on the link
Instructor: TRAN THI TUAN ANH 30 / 31
OVERVIEW
THE END