我试图使用.add_subplot()
绘制多个直方图
以下是我的代码的一部分:
for j in range(nlayer):
p_value_tensor_Wiki103_at_layer_j = p_value_tensor_Wiki103_at_layer[:,j].tolist()
hist_j = fig.add_subplot(grid[0,j], xticklabels=[], yticklabels=[])
hist_j.set_xlabel(labels_Wiki103[j],fontsize=3)
# histogram on the attached axes
hist_j.hist(p_value_tensor_Wiki103_at_layer_j, bins = 20)
但是如果我想在我生成的每个子图上添加一条x=0.05的垂直线,我应该怎么做
谢谢,
使用^{} 或^{} ,用法:
在您的用例中,您只需要
相关问题 更多 >
编程相关推荐