博客
关于我
2020-12-27
阅读量:691 次
发布时间:2019-03-17

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

安装 matplotlib-3.3.3(Python 3.9版本)详细步骤

准备工作

1. 确保系统上预装了 Python 3.9 及可用版本的 pip

  • 在命令提示符中输入 python -v 确认 Python 版本,确保版本为 3.9 或以上
  • 输入 pip --version 查看 pip 版本,确认确实可用

2. 下载指定版本的 matplotlib

  • 访问matplotlib官方下载页面(请自行替换为合适的链接)
  • 查找对应 Python 3.9 的安装包版本
  • 下载矫正的 .whl 文件(搜索方法:在(blog.csdnimg.cn 或其他博客资源库)输入关键词:matplotlib-3.3.3 cp39 cp39-win_amd64.whl)

安装步骤

1. 打开命令提示符时,切换至 Python 根目录

  • 在资源管理器里右键点击已安装的 Python 3.9 文件夹
  • 选择“以管理员身份运行”然后打开 Command Prompt

2. 安装 matplotlib

  • 输入 pip3.9 (若只看到 pip,提示可能需要管理员权限)
  • 输入命令:pip3.9 install "matplotlib-3.3.3-cp39-cp39-win_amd64.whl"

验证安装

1. 查看安装版本

  • 在 CMD 中输入:python -m matplotlib.pyplot
  • 输出应类似:Python 3.9.x 的 matplotlib 3.3.3 被安装

2. 测试绘图功能

  • 输入代码:

    import matplotlib.pyplot as pltplt.plot([1,2,3], 'b--')plt.show()

注意事项

  • 国内用户建议使用清华镜像站点或 TessuShare 代替直接从 pypi 获取
  • 安装时保持 Command Prompt 窗口打开,默认模式下可能会自动关闭
  • 需要管理员权限安装?请确认您是否有足够的权限操作(如保存的 wheel 文件正确路径)

如有安装失败或其他问题,请参考matplotlib官方文档(注:链接仅供参考,实际操作请自行替换)。祝您操作顺利!

转载地址:http://gkdhz.baihongyu.com/

你可能感兴趣的文章
prometheus + grafana进行服务器资源监控
查看>>
Prometheus Alertmanager 告警配置详解
查看>>
Prometheus Grafana 展示平台
查看>>
Prometheus pushgateway使用详解
查看>>
Prometheus 云原生 - Prometheus 数据模型、Metrics 指标类型、Exporter 相关
查看>>
Prometheus 云原生 - 基于 file_sd、http_sd 实现 Service Discovery
查看>>
Prometheus 云原生 - 微服务监控报警系统 (Promethus、Grafana、Node_Exporter)部署、简单使用
查看>>
Prometheus 云原生 - 监控 Linux、MySQL、Redis、RabbitMQ、Docker、SpringBoot 3.x
查看>>
Prometheus 介绍
查看>>
Prometheus 安全配置详解
查看>>
prometheus 安装node_exporter, node_exporter 安装最新版 普罗米修思安装监控服务器client
查看>>
Prometheus 安装部署实战
查看>>
prometheus 持久化存储方案
查看>>
Prometheus 监控系统企业级实战
查看>>
Prometheus 监控系统简介
查看>>
Prometheus 配置详解
查看>>
Prometheus 采集器使用详解
查看>>
Prometheus 黑盒监控实战
查看>>
prometheus+alertmanager+grafana监控部署教程
查看>>
Prometheus+Grafana构建智能化Kubernetes监控系统实战
查看>>