0

I've seen several posts here all saying "Go go Python › Data Science: Text Output Limit" but that setting does not exist in my VSCode or I'm too dumb to find it.

Has something changed?

How do I make VSCode diplay the full .csv I've imported?

It's [232 rows x 32 columns] but VSCode is only showing 10 rows - I get 0-4 and 227-231, everything in the middle is missing.

The number of columns changes depending on how wide the console window is.

edit more info: I am using pandas and python 3.10, MS Python extension, and outputting to a vscode termial window.

enter image description here

Goblynn93
  • 21
  • 5
  • It's not missing! It's a constraint for better use of space! You can't see all the rows of your dataframe either in the Jupyter notebook or in Pycharm! This behavior is not specifically related to VSCode! But I guess you can change that constraint in VSCode. – Shayan Feb 16 '22 at 20:56
  • "Better use"? I'm confused with that concept. Better use of space for me would be to give me a horizontal scroll bar so I can see the entire table laid out at once. I have other options for that but I was hoping to not use another extension or external app. Its kind of annoying the way it cuts things off. – Goblynn93 Feb 17 '22 at 21:19

1 Answers1

0

It's not related to the VSCode, it's pandas related. Like @Shayan provided, you can configure pandas like this:

pd.set_option('display.max_rows', 500)
pd.set_option('display.max_columns', 500)
pd.set_option('display.width', 1000)
Steven-MSFT
  • 7,438
  • 1
  • 5
  • 13
  • Yeah I figure that out much later. But that still doesn't get me what I want: it will word wrap and cut things and do all kind of other ugly if I set width to 1000. Why can't it just give me a horizontal scroll bar and fill out the space I asked for? – Goblynn93 Feb 17 '22 at 21:24
  • @Goblynn93 Someone has submit a feature request on GitHub, you can refer to [here](https://github.com/microsoft/vscode/issues/74501). – Steven-MSFT Feb 18 '22 at 03:05