Skip to content

read_excel documentation does not mention names keyword #11468

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
PBrockmann opened this issue Oct 29, 2015 · 1 comment · Fixed by #11874
Closed

read_excel documentation does not mention names keyword #11468

PBrockmann opened this issue Oct 29, 2015 · 1 comment · Fixed by #11874
Labels
Docs IO Excel read_excel, to_excel
Milestone

Comments

@PBrockmann
Copy link

http://pandas.pydata.org/pandas-docs/stable/generated/pandas.read_excel.html
does not mention the keyword "names"

import pandas as pd
df = pd.read_excel('yourfile.xls', header=None, names=['Attribut', 'Value'])

is equivalent but simpler to

df = pd.read_excel(file, sheetname='Metadata', header=None)
df.columns = ['Attribut', 'Value']

names keyword is defined as in read_csv
names: List of column names to use as column names. To replace header existing in file, explicitly pass header=0.

@jreback
Copy link
Contributor

jreback commented Oct 29, 2015

suppose that's reasonable. a number of parameters are actually passed thru to read_csv.

a pull-request to add to the doc-string (and as a named parameter) would be helpful.

@jreback jreback added Docs IO Excel read_excel, to_excel labels Oct 29, 2015
@jreback jreback added this to the Next Major Release milestone Oct 29, 2015
@jorisvandenbossche jorisvandenbossche modified the milestones: 0.18.0, Next Major Release Dec 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Docs IO Excel read_excel, to_excel
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants