安装好python环境后,为了方便后续代码编写,可以:
一、先设置安装服务器为国内的镜像(任选一个,执行一次):
豆瓣:
pip config set global.index-url http://pypi.douban.com/simple/
pip config set install.trusted-host pypi.douban.com
清华:
pip config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
pip config set install.trusted-host pypi.tuna.tsinghua.edu.cn
阿里云:
pip config set global.index-url https://mirrors.aliyun.com/pypi/simple/
pip config set install.trusted-host pypi.tuna.tsinghua.edu.cn
二、在python的终端(terminal)或jupyter notebook里面输入:pip install 软件包名字
sklearn机器学习包的安装命令
pip install scikit-learn
apriori关联分析安装包的安装命令
pip install apyori
networkx社会网络分析安装包
pip install networkx
tensorflow神经网络安装包
pip install tensorflow
三、Jupyter notebook的安装与使用
先设置环境变量(在windows电脑高级系统设置中,点击环境变量->系统变量->path,点击编辑,在弹出的窗口点击新建,输入C:\ProgramData\anaconda3\Scripts,再点击确定),然后就可以在电脑左下角搜索处输入cmd打开命令提示符,在弹出的窗口中输入jupyter notebook回车,会打开一个浏览器,这就是jupyter的界面,建议点击desktop进入桌面进行文件的建立与代码编写。
如果还没有安装jupyter notebook,可以在cmd命令提示符中输入pip install notebook,然后回车进行安装。

