Skip to content
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

Switch cols to kwarg from positional args #2023

Closed
bkamins opened this issue Nov 26, 2019 · 2 comments
Closed

Switch cols to kwarg from positional args #2023

bkamins opened this issue Nov 26, 2019 · 2 comments
Milestone

Comments

@bkamins
Copy link
Member

bkamins commented Nov 26, 2019

Following the comment by @nalimilan in #2020 after seeing what changes I make in #1958 currently I came to the conclusion that we should cleanup cols to be a keyword argument everywhere.

This should be changed prior to 1.0 release, but is non-blocking for 0.20 I think. I will make a PR for this.

@bkamins bkamins added this to the 1.0 milestone Nov 26, 2019
@bkamins
Copy link
Member Author

bkamins commented Nov 30, 2019

@nalimilan Here is the result of cols usage review.

cols is a positional argument in:

  • sort and issorted (actually we have a reverse deprecation to what we discuss in these cases)
  • allowmissing
  • disallowmissing
  • categorical
  • completecases
  • dropmissing
  • nonunique
  • unique
  • disallowmissing
  • grouping
  • getindex
  • view
  • DataFrameRow and SubDataFrame constructors

cols is a kwarg in:

  • describe is kwarg
  • vcat is kwarg but has a broader meaning
  • push! and append! has a different meaning

Given this I recommend to leave things "as is", as we would change a bunch of stuff to make a rarely used functionality consistent.
Only describe is really conflicting with what we do currently (cols as positional arg).
In describe it is natural to have cols as kwarg as there is no other option, so there should be no confusion.
vcat, push! and append! are different anyway and also I think there should be no confusion.

What is your opinion? I would just close this issue.

@nalimilan
Copy link
Member

OK, thanks for checking. Let's leave this as-is then.

@bkamins bkamins closed this as completed Nov 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants