zsh2270365028的个人博客分享 http://blog.sciencenet.cn/u/zsh2270365028

博文

[转载]matplotlib隐藏刻度线、标签和边线

已有 3164 次阅读 2022-2-16 16:51 |个人分类:Python|系统分类:科研笔记|文章来源:转载

refer to: https://blog.csdn.net/weixin_43326122/article/details/107292857

https://www.delftstack.com/zh/howto/matplotlib/how-to-hide-axis-text-ticks-and-or-tick-labels-in-matplotlib/

https://blog.csdn.net/qq_41181787/article/details/105264825


 

一般情况

在这里插入图片描述




以下ax默认由plt.gca()plt.subplots()获得

隐藏所有刻度线和标签

在这里插入图片描述

隐藏刻度线和标签

plt.yticks([])结果

隐藏刻度线

在这里插入图片描述

隐藏边线

在这里插入图片描述


刻度设置
标签设置
子图相关
设置子图之间的间距
删除右边框和上边框
seaborn.boxplot不显示离群点
使用sns.clutermap函数时,设置坐标轴刻度旋转的方式




https://m.sciencenet.cn/blog-587102-1325592.html

上一篇:[转载]matplotlib隐藏刻度线、标签和边线
下一篇:[转载]python Log Axis

0

该博文允许注册用户评论 请点击登录 评论 (0 个评论)

数据加载中...
扫一扫,分享此博文

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-5-16 02:57

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部