Introduction and installation of Anaconda with a series of third-party libraries

  主要会写这个是因为前几天的Python量化投资课老师讲过一遍问大家下来安装没,几乎没人回答。我觉得我还是操作一下吧,总不能真的让老师白讲了。(也不能白交学费真一点不学是吧 哈哈哈)

1. Introduction to Anaconda

    Anaconda是在Windows、Linux、和Mac OS X上执行Python数据科学和机器学习的一个极其方便的平台。同时,它也是一个关于Python和R的编程语言的免费增值的开源发行版。

Two, Anaconda features

   它自带Numpy、Pandas、Matplotlib、Seaborn等一系列数据分析和机器学习领域功能强大的第三方库,集数据分析、数据可视化、机器学习模型开发和训练于一体。
   也就是说,如果我们安装了Anaconda,就不需要再专门的一个个安装第三方库。只要在使用Pycharm时调用Anaconda环境,便可以方便的使用其中的各种库,就不用面临分别安装各个库且还要考虑安装地址及调用等问题。
   同时各个第三方库之间有较强的粘性,各个库之间的依赖性很好,对我们来讲可以大大简化安装流程。

3. Anaconda installation

Download and install

   安装之前先到Anaconda的官网https://www.continuum.io/downloads下载Anaconda。
   Python有python2.x和python3.x两种,目前对于我们主要是语言细节上的不同,没有很大差异。大家根据自身电脑的操作系统来选择相应的版本进行下载安装。
   由于大家普遍使用Windows系统,这里详细演示Windows系统下的安装,Windows系统32位和64位根据自己的电脑进行选择。
   下面我们详细演示安装3.10版本:

insert image description here

insert image description here

Click Next to enter the next step interface as shown in the figure.
insert image description here
Continue to I agree, select just me and
insert image description here
the interface as shown in the figure below appears. In the "Destination Folder" target path, select the path where you want to install Anaconda. It is recommended to install it to a place with more space plate.
insert image description here
After clicking Next again, you come to the last step before starting the installation. The interface is shown in the figure below. The option I did not check above is to add Anaconda to the path environment variable, which can be selected; the one I chose below is to set Anaconda It is the default Python interpreter, it is recommended that you choose it.

insert image description here
Clicking install will start the installation, and the installation will be successful after a few minutes.

Check if the installation is successful

   安装完成后,我们需要检查安装是否真的成功了,打开 windows 的命令提示符(cmd窗口:首先使用“Win+R”快捷键召唤出运行窗口,再在运行中输入 cmd,点击确认即可打开):

insert image description here
Enter conda list to check which libraries are currently installed. Commonly used NumPy, Pandas, SciPy, Matplotlib, Jupyter, etc. have been automatically installed. This step is equivalent to checking.
insert image description here
Even if the complete installation is complete here.

Four, Anaconda environment creation

 在Anaconda Navigator的“Environment”界面中,显示了Anaconda在本机建立起来的Python环境,Anaconda可以在本机建立起多个不同的环境,中间栏的base(root)就是Anaconda安装目录下的环境,点击creat可创建一个新环境,如下图所示。

insert image description here

The right column displays various Python programs and third-party libraries that have been installed in this environment. Click the Installed drop-down option in the upper left corner of the right column to view installed, uninstalled, and all libraries that can be installed through Anaconda and updates. , 442 libraries or programs are currently installed.

insert image description here

insert image description here

   点击未安装库前面的▢,Anaconda将自动分析安装包需要的相关软件包是否安装并进行相关安装。
   我们在右上角的搜索框里输入“scipy”搜索scipy库,点击库名前面的√我们可以卸载scipy库,或者将scipy库回滚回之前的版本。Environment点击选项回退版本如下图所示。库后面的版本号为蓝色表示该库可更新。

insert image description here
The above is about the installation of the Anaconda library and the operation of the environment. This article refers to what the teacher taught in class, as well as related documents and textbooks on quantitative investment in Python.

Guess you like

Origin blog.csdn.net/qq_62939934/article/details/130304645