Skip to content

DOC: Documentation says Series.items(), Series.iteritems() are equivalent to DataFrame.items(), but they're not. #27859

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
benthayer opened this issue Aug 11, 2019 · 2 comments · Fixed by #27888
Labels

Comments

@benthayer
Copy link
Contributor

Documentation says Series.items(), Series.iteritems() are equivalent to DataFrame.items() for DataFrames, but they're not. Instead, they are equivalent to DataFrame.iterrows()

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Series.items.html

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Series.iteritems.html

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.items.html

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.iterrows.html

@jorisvandenbossche
Copy link
Member

I think this is more a semantic discussion about what "equivalent" means here, but feel free to propose a better description of the relation between Series.items() and DataFrame.items()

@jorisvandenbossche jorisvandenbossche changed the title Documentation says Series.items(), Series.iteritems() are equivalent to DataFrame.items(), but they're not. DOC: Documentation says Series.items(), Series.iteritems() are equivalent to DataFrame.items(), but they're not. Aug 12, 2019
@TomAugspurger
Copy link
Contributor

Right. They're equivalent in the sense that you get an iterator over "key, value" pairs.

I think this is fine, but would certainly accept a PR clarifying things. I don't think we necessarily need an open issue for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants