pandas实现DataFrame显示最大行列,不省略显示实例
作者:起飞的木木 时间:2023-10-27 14:08:52
如下所示:
import pandas as pd
#显示所有列
pd.set_option('display.max_columns', None)
#显示所有行
pd.set_options('display.max_rows', None)
None可以写具体的数字,写多少就显示多少,默认是显示100行
import pandas as pd
pd.set_option('display.height', 1000)
pd.set_option('display.max_rows', 500)
pd.set_option('display.max_columns', 500)
pd.set_option('display.width', 1000)
类似的,对于numpy array print后不能完全显示输入下面代码:
numpy.set_printoptions(threshold = np.inf)
#若想不以科学计数显示:
numpy.set_printoptions(suppress = True)
来源:https://blog.csdn.net/qifeidemumu/article/details/88816065
标签:pandas,DataFrame,行列
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Vue图片裁剪功能实现代码
2024-05-29 22:50:11
![](https://img.aspxhome.com/file/2023/6/122986_0s.png)
全面了解python中的类,对象,方法,属性
2021-10-07 10:54:50
golang time包的用法详解
2024-04-25 13:19:19
IE bug: 1像素的dotted/dashed边框
2009-10-28 18:45:00
![](https://img.aspxhome.com/file/UploadPic/200910/28/dotted-1px-59s.jpg)
$.browser.msie 为空或不是对象问题的多种解决方法
2024-05-11 09:33:55
Django-migrate报错问题解决方案
2021-11-05 13:30:16
面试官问订单ID是如何生成的?难道不是MySQL自增主键
2024-01-24 00:36:24
![](https://img.aspxhome.com/file/2023/3/129923_0s.jpg)
python制作抖音代码舞
2021-09-05 21:51:00
![](https://img.aspxhome.com/file/2023/8/105088_0s.jpg)
Golang中数据结构Queue的实现方法详解
2024-04-26 17:20:00
PyQt5每天必学之拖放事件
2021-02-28 19:26:15
![](https://img.aspxhome.com/file/2023/1/97191_0s.png)
[翻译]标记语言和样式手册 Chapter 16 下一步
2008-02-22 17:47:00
GO语言异常处理机制panic和recover分析
2024-02-18 01:58:36
SqlServer查询和Kill进程死锁的语句
2024-01-23 11:07:42
常用Oracle分析函数大全
2023-07-03 08:16:14
![](https://img.aspxhome.com/file/2023/0/63710_0s.jpg)
零基础写python爬虫之使用urllib2组件抓取网页内容
2021-08-16 01:13:22
![](https://img.aspxhome.com/file/2023/1/127871_0s.png)
python判断字符串或者集合是否为空的实例
2021-08-03 04:08:58
去除python中的字符串空格的简单方法
2022-11-01 10:33:22
详解利用Python scipy.signal.filtfilt() 实现信号滤波
2022-09-23 21:23:03
SQL存储过程初探
2009-09-09 14:22:00
![](https://img.aspxhome.com/file/UploadPic/20099/9/cccr-25s.jpg)
pandas分组聚合详解
2023-06-28 15:50:25