anaconda安装不同版本python,如何在Anaconda中为不同的Python版本安装软件包?
发布日期:2021-11-18 06:42:31 浏览次数:2 分类:技术文章

本文共 770 字,大约阅读时间需要 2 分钟。

I have Python 2.7 as root. I need to install the package "statistics" in Python 3.6, and it is not in the environments of anaconda navigator. How can install "statistics" with conda or pip for a secondary Python environment?

解决方案

Create a new Python 3 environment by running:

conda create --name python3 python=3

If you want all the standard anaconda packages installed by default, do:

conda create --name python3 python=3 anaconda

Whenever you need to use python3 run:

activate python3

Then use the command line as normal. So, if you want to install something into your python3 environment, make sure you activate python3 first.

Note that python 3 has it's own statistics module that you may find useful, and this module has been ported to python 2 if you would prefer.

转载地址:https://blog.csdn.net/weixin_33648352/article/details/118803075 如侵犯您的版权,请留言回复原文章的地址,我们会给您删除此文章,给您带来不便请您谅解!

上一篇:gitlab 构建tag,GitLab CI-添加标签时避免构建
下一篇:计算机网络原理统考题,计算机网络原理考试题及答案

发表评论

最新留言

哈哈,博客排版真的漂亮呢~
[***.90.31.176]2024年04月05日 21时13分03秒