Pandas: feature wanted: pd.DataFrame.info() should show line numbers

Created on 22 Aug 2017  路  5Comments  路  Source: pandas-dev/pandas

Problem description

When we load data frames, sometimes there are warning of mixed types on some columns via index of columns. It will be then easier for us to check which column is it (by name) if the indices (i.e. line numbers) are shown in pd.DataFrame.info().

Enhancement Error Reporting good first issue

Most helpful comment

Should probably be 0 indexed.

All 5 comments

Can you give an example? Is this when loading the data, or calling .info()? By the time you have a DataFrame and call .info all the information about where it was loaded from will be gone.

Sorry, I may have confused you. What I mean is I wish for a handy feature of pd.DataFrame.info() which can show line numbers. For example, when we call it the result is sth like:
Data columns (total n columns):

  1. name type
  2. name type
    ...
    n. name type

I guess that is reasonable. If you would like to submit a PR would be ok.

Should probably be 0 indexed.

Does this issue still need to be resolved? I would be happy to tackle this otherwise.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

BDannowitz picture BDannowitz  路  3Comments

marcelnem picture marcelnem  路  3Comments

Abrosimov-a-a picture Abrosimov-a-a  路  3Comments

matthiasroder picture matthiasroder  路  3Comments

Ashutosh-Srivastav picture Ashutosh-Srivastav  路  3Comments