Python
Java
PHP
IOS
Android
Nodejs
JavaScript
Html5
Windows
Ubuntu
Linux
matplotlib:在次要标签下绘制主要刻度标签
这看起来应该很容易 但我不知道该怎么做 我有一个 X 轴上有时间的图 我想设置两组刻度 小刻度显示一天中的小时 大刻度显示日 月 所以我这样做 set date ticks to something sensible xax ax get
python
matplotlib
plot
axislabels
如何确保我的 matplotlib 轴属于自定义类?
我有一个自定义图形类 并希望确保与其关联的所有轴 无论是使用subplots or twinx 等具有自定义行为 现在 我通过在创建每个轴后将新方法绑定到每个轴来实现这一点 例如通过使用 import types def my ax met
python
matplotlib
subclassing
axes
figures
如何在 Matplotlib 中编写自己的 LaTeX 序言?
我正在尝试创建一个数字matplotlib插入我的LaTeX文档 我需要粗体 i and j 没有圆点和帽子的符号 我一直在使用代码 mathbf hat textnormal bfseries i 在我的文档中 但由于这使用了amsmat
python
matplotlib
latex
在 Jupyter 笔记本中使用 Matplotlib 进行交互式绘图时,图形未填充画布
我正在尝试做这样的事情来仔细查看我的数据 目前在 Jupyter iPython 中动态更新绘图的正确方法是什么 https stackoverflow com questions 34486642 what is the currentl
python
matplotlib
jupyternotebook
Matplotlib 文本尺寸
是否可以确定 matplotlib 文本对象的尺寸 如何找到以像素为单位的宽度和高度 Thanks Edit 我想我已经找到办法了 我在下面举了一个例子 import matplotlib as plt f plt figure r f c
python
matplotlib
matplotlib 后端对渲染格式有什么限制?
我对 matplotlib 使用的后端在确定可以呈现哪些格式方面所扮演的角色感到困惑 例如 文件说 http matplotlib org faq usage faq html what is a backend agg 后端生成 PNG
python
matplotlib
format
Rendering
使用 pandas 绘制带有误差线的条形图
我正在尝试从 DataFrame 生成条形图 如下所示 Pre Post Measure1 0 4 1 9 这些值是我从其他地方计算出来的中值 我还有它们的方差和标准差 以及标准误差 我想将结果绘制为具有适当误差线的条形图 但指定多个误差值
python
matplotlib
pandas
Matplotlib 将颜色图 tab20 更改为三种颜色
Matplotlib 有一些新的且非常方便的颜色图 选项卡颜色图 https matplotlib org examples color colormaps reference html 我错过的是生成像 tab20b 或 tab20c 这
python
matplotlib
如何获取 Matplotlib 生成的散点图的像素坐标?
我使用 Matplotlib 生成散点图的 PNG 文件 现在 对于每个散点图 除了 PNG 文件之外 我还会also就像生成散点图中各个点的像素坐标列表一样 我用来生成散点图 PNG 文件的代码基本上是这样的 from matplotli
python
matplotlib
如何在 plt.show() 之后保持脚本运行[重复]
这个问题在这里已经有答案了 之后plt show 我只想继续 但需要关闭弹出图 我该怎么做才能跳过该操作 这是我的代码 plt show time sleep 1 plt close all 其他代码 还有一个关于如何最大化数字制作的问题p
python
matplotlib
Matplotlib:生成具有不同和倒置比例的多个双轴
我想在两个 x 和 y 轴上绘制一个数据系列 以便有 4 个不同的轴 首先是 x 以 eV 为单位的能量 与 y 归一化计数 轴 然后是 x 与能量成反比的波长 与 y 计数 轴 我的代码是 import numpy as np impor
python
matplotlib
Scaling
axes
对列中的字符串进行排序并打印图表
我有数据框 但所有字符串都是重复的 当我尝试打印图表时 它包含重复的列 我尝试删除它 但我的图表打印不正确 我的 csv 是here https yadi sk i rOYxzv26qQans 数据框common users used at
python
pandas
matplotlib
如何为我的杆和楔子添加纹理?
我正在使用绘制几个条形图和饼图matplotlib pyplot bar http matplotlib org api pyplot api html matplotlib pyplot bar and matplotlib pyplot
python
matplotlib
Shap - 颜色条不显示在摘要图中
显示summary plot时 不显示颜色条 shap summary plot shap values X train 我尝试过改变plot size 当绘图较高时 会出现颜色条 但它非常小 看起来不应该 shap summary plo
python
matplotlib
shap
使 matplotlib 图形默认看起来像 R?
Is there a way to make matplotlib behave identically to R or almost like R in terms of plotting defaults For example R t
python
r
matplotlib
plot
pandas
如何在matplotlib中基于x轴更改直方图颜色
我有根据 pandas 数据框计算出的直方图 我想根据 x 轴值更改颜色 例如 If the value is 0 the color should be green If the value is gt 0 the color shoul
python
pandas
matplotlib
Histogram
绘制“plot”而不是“scatter”时,图例选择会中断
再会 这个问题是后续问题为什么图例选取仅适用于 ax twinx 而不适用于 ax https stackoverflow com q 60167378 9282844 下面提供的最小代码分别绘制了两条曲线ax1 and ax2 ax1 t
python
matplotlib
将 matplotlib png 转换为 base64 以在 html 模板中查看
背景 你好 我正在尝试制作一个简单的网络应用程序 按照教程计算阻尼振动方程 并将结果的 png 返回到 html 页面 然后将其转换为 Base64 字符串 Problem 该应用程序运行正常 只是在计算结果时返回损坏的图像图标 可能是因为
python
html
matplotlib
Flask
Base64
python中热图的层次聚类
我有一个 NxM 矩阵 其值范围为 0 到 20 我可以使用 Matplotlib 和 pcolor 轻松获得热图 现在我想使用 scipy 应用层次聚类和树状图 我想重新排序每个维度 行和列 以显示哪些元素相似 根据聚类结果 如果矩阵是方
python
matplotlib
Heatmap
hierarchicalclustering
dendrogram
在 Plotly Density_Mapbox 上添加 GeoJSON 等高线作为图层
我想在上面添加天气轮廓plotly density mapbox地图 但我不确定必要的步骤 首先 我创建了一个matplotlib等值线图以可视化数据 然后 我用了geojsoncontour创建一个geojson文件来自所说matplot
python
matplotlib
plotly
GeoJson
contour
«
1
2
3
4
5
6
...100
»