Closed
Description
Don't know if this is related to the new changes in 0.14 in the display of Dataframes or to #7180. But I find the following behaviour with 0.14 in Spyders IPython qtconsole:
To reproduce:
df = pd.DataFrame(np.random.randn(2,20), columns=list('ABCDEFGHIJKLMNOPQRST'))
df['very_long_column_name'] = [1,2]
df['X'] = ['very_long_column_values', 'other_long_string']
- This seems not a very usefull behaviour to me?
Should it truncate on width rather than number of columns? - It is also not truncating (above dataframe has 22 columns, while default
max_columns
is 20 (and I checked the setting)), while it truncated correctly for the text repr.
Other strange thing, I saw this in the Spyder IPython console (which is an embedded qtconsole I think). However, when I tried this in a qtconsole, it gave me first the text repr instead of the html repr (although pd.options.display.notebook_html_repr
was set to True), so I used HTML(df.to_html())
for the above picture (but the result is the same as in Spyder).