简体   繁体   English

如何使用 Jupyter 笔记本在 Pandas 中打印出我在 csv 文件中的每个数据值

[英]How do I print out every value of data I have inside my csv file in Pandas using Jupyter notebook

I have a large pokemon data that is saved as a csv file.我有一个保存为 csv 文件的大型口袋妖怪数据。 I just wanna say that I am a complete novice in here so this might be a very basic error but I'd still like it to be posted.我只想说我在这里是一个完全的新手,所以这可能是一个非常基本的错误,但我仍然希望它被发布。 I know how to print and make a dataframe, I've tried that but the problem is that I wanna see every single bit of data inside my csv file.我知道如何打印和制作 dataframe,我已经尝试过了,但问题是我想查看 csv 文件中的每一位数据。 The csv file has 800 rows x 12 columns. csv 文件有 800 行 x 12 列。 And whenever I print it out in my jupyter notebook it just shows 4 of the first values and 4 of the last values.每当我在我的 jupyter 笔记本中打印出来时,它只会显示 4 个第一个值和 4 个最后一个值。 Which is not what I want.这不是我想要的。 I tried both print it directly df , using the print() , and also creating a dataframe datas = pd.DataFrame(df) datas .我尝试使用print()直接打印它df ,还尝试创建 dataframe datas datas = pd.DataFrame(df) datas But all of which seemed to do the same thing.但所有这些似乎都在做同样的事情。

TL;DR: I wanna print out every data inside my csv file in jupyter but it only prints out 4 of the first values and 4 of the last values. TL;DR:我想在 jupyter 中打印出我的 csv 文件中的所有数据,但它只打印出第一个值中的 4 个和最后一个值中的 4 个。

Thank you in advance!先感谢您!

Try尝试

pd.set_option('display.max_rows', None)
pd.set_option('display.max_columns', None)

And in the next cell you can print df在下一个单元格中,您可以打印 df

print(df)

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 我如何使用 jupyter 笔记本的 python 代码从网站下载 csv 文件 - how do i download the csv file from a website using python code for my jupyter notebook 在 jupyter 笔记本中,我使用 pandas 打开了一个 csv 文件,其中包含与游戏相关的数据,包括它们的最后更新日期 - In jupyter notebook, i have opened a csv file using pandas that has data related to games including their last update date 如何使用pyspark在jupyter笔记本中显示我的csv数据文件 - How can i show my csv data file in jupyter notebook using pyspark 如何从使用熊猫上传的大型CSV文件中仅打印出某些行 - How do I print out only certain rows from a large CSV file uploaded using pandas 如何在 Jupyter Notebook 中阅读此 CSV? - How do I read this CSV in Jupyter Notebook? 为什么每次启动jupyter notebook时都必须导出浏览器才能运行? - Why do I have to export my browser every time I launch jupyter notebook for it to work? 每次运行 Jupyter Notebook 时,是否必须使用 fetch_openml 重新下载 MNIST? - Do I have to redownload MNIST with fetch_openml every time I run my Jupyter Notebook? 如何在 Jupyter 笔记本中使用 Python 和 pandas 从特定列中提取数据? - How do I pull data from a specific column using Python and pandas in a Jupyter notebook? 如何使用Pandas库打印数据集(CSV文件)的尺寸并打印一些行? - How do I print the dimensions of a dataset (csv file) using Pandas- library and also print out some lines? 我如何使用谷歌云自动化我的 jupyter notebook? - How do i automate my jupyter notebook using google cloud?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM