Installation of anaconda and jupyter notebook for Ubuntu


1、 Install Anaconda

Download Anaconda of the corresponding version of Python 3 installed in Ubuntu from the official website. This installation is Python 3.5. Find Anaconda version of Anaconda 4.2.0 from the Internet. The following is the installation process:

Download various versions on the official website:

1. Enter download path

cd Downlads/

2. Install Anaconda


Follow the prompts

3. Update environment variables after installation

source ~/.bashrc

4. Enter Python 3 again

5. See if the last line has an added path

gedit ~/.bashrc



6. Make environment variables effective

source ~/.bashrc

2、 Installation   Jupyter Notebook

(1) —— install using CONDA. The premise is that anaconda is installed

1. Upgrade CONDA

  conda update conda

2. Install Jupiter notebook

  conda install jupyter notebook

(1) —— you can also use PIP3 for installation

1. Update PIP3

  pip3 install –upgrade pip

2. Install Jupiter notebook

  pip3 install jupyter

(2) —— start Jupiter notebook

  jupyter notebook

By default, the browser address bar will display:http://localhost:8888。 Where, “localhost” refers to the local computer, and “8888” refers to the port number. If multiple Jupiter notebooks are started at the same time, since the default port “8888” is occupied, the number in the address bar will start from “8888”, and 1 will be added for each additional Jupiter notebook, such as “8889”, “8890”

(3) —— specify the port number to start
  jupyter notebook –port
For example, Jupiter notebook — port 8889 starts with this port number
(4) Modify the file storage path of Jupiter notebook
1. Create folder
  mkdir Jupyter_file
2. Enter this folder
  cd Jupyter_file
3. View the path and copy it
Copy the path
4. Modify profile
  vim ~/.jupyter/
Enter the file
Then enter / c.notebookapp.notebook in this interface_ Dir and press enter to find Jupiter_ notebook_ In the file, press I to enter the editing mode, paste the file directory to this place, and then delete #, which is the comment of Python. Then save and exit, that is, press ESC, then enter: WQ, enter.
Note that it must be in English
5. After opening again, the directory under this path.