Jupyter Notebook is the most used tool in the scientific community to run python and r programming hence let’s learn how to install Anaconda and run Pandas programs on Jupyter notebook. In this article, I will cover step-by-step instructions of installing anaconda and running pandas programs on Jupyter Notebook.
- Anaconda is the most used distribution platform for python & R programming languages in the data science & machine learning community as it simplifies the installation of packages like pandas, NumPy, SciPy, and many more. Conda is the package manager that the Anaconda distribution is built upon. It is a package manager that is both cross-platform and language agnostic. We can use conda to install any third-party packages.
- Pandas is an open-source framework in Python to works with tabular data (rows and columns). pandas have DataFrame which is a two-dimensional data table and Series one dimensional. pandas will help you to explore, clean, and process your data in easy steps
- Jupyter Notebook is an interactive web UI environment to create notebook documents for python, R languages. Jupyter Notebook documents take statements similar to REPL additionally it also provides code completion, plots, and rich media.
Table of Contents:
- Download & Install Anaconda Distribution
- Install pandas on Anaconda
- Run pandas From the Command Line
- Run pandas From the Jupyter Notebook
1. Download & Install Anaconda Distribution
Follow the below step-by-step instructions to install Anaconda on windows. If you already have anaconda distribution installed then jump to Run pandas From the Command Line section.
1.1 Download Anaconda Distribution
Go to https://anaconda.com/ and select Anaconda Individual Edition to download the latest version of Anaconda. This downloads the
.exe file to the windows download folder.
1.2 Install Anaconda on Windows
By double-clicking the .exe file starts the Anaconda installation. Follow the below screen shot’s and complete the installation
This finishes the installation of Anaconda distribution. Now let’s see how to install pandas.
2 Installing pandas using conda command
2.1 Open Anaconda Navigator from the Windows Start or Search Box.
2.2 Create Anaconda Environment
This is optional but recommended to create an environment before you proceed. This gives complete segregation of different package installs for different projects you would be working on. If you already have an environment, you can use it too.
2.3 Open Anaconda Terminal
You open the Anaconda terminal from
Anaconda Navigator or open it from the windows start menu/search.
2.4 Install Pandas using conda
conda install pandas to install pandas in your environment. Note that along with pandas it also installs several other packages including the most used
3. Run pandas From Command Line
now open Python terminal by entering
python on the command line and then run the following command at prompt >>>.
>>> import pandas as pd
Writing pandas commands from the terminal is not practical in real-time.
4. Run pandas From Jupyter Notebook
let’s see how to run panda programs from
Go to Anaconda Navigator -> Environments -> your environment (mine pandas-tutorial) -> select Open With Jupyter Notebook
This opens up Jupyter Notebook in the default browser.
Now select New -> PythonX and enter the below lines and select Run.
This completes installing Anaconda and runnings pandas on Jupyter Notebook. If you have any issues installing, please comment below. Your comments might help others.
Happy Learning !!
Frequently Asked Questions
Anaconda is an open-source distribution of Python and R programming languages for scientific computing, that aims to simplify the package management and deployment of various libraries and tools. It includes a package manager (conda) and a collection of pre-installed libraries, making it easier to set up and manage environments for data science and machine learning.
Visit the Anaconda website.
Download the appropriate version of Anaconda for your operating system (Windows, macOS, or Linux).
Follow the installation instructions provided on the website.
Jupyter Notebook is an open-source web application that allows you to create and share documents that contain live code, equations, visualizations, and narrative text. It is widely used in data science, research, and education for interactive computing and data analysis.
Open the Anaconda Navigator (you can find it in your applications or programs menu).
Launch the Jupyter Notebook from the Navigator.
This will open a new tab in your web browser, displaying the Jupyter Notebook dashboard.
On the Jupyter Notebook dashboard, click on the “New” button and select “Python 3” (or any other available kernel).
This will open a new notebook where you can input code, text, and visualizations.
- How to Install Anaconda on Windows
- How to Install Anaconda & Run Jupyter Notebook
- Install Pandas on Windows Step-by-Step
- Update Jupyter Notebook or Jupyterlab
- Install Python Pandas on Windows, Linux & Mac
- Install Jupyter Notebook or Jupyterlab on Mac OS
- JupyterLab Error – JupyterLab application assets not found