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

mutate(index = row_number()) fails on an empty frame (version 0.3.0.2) #762

Closed
sbisaacson opened this issue Nov 11, 2014 · 2 comments
Closed
Assignees
Labels
bug an unexpected problem or unintended behavior
Milestone

Comments

@sbisaacson
Copy link

The command

mutate(frame, index = row_number())

fails if nrow(frame) == 0:

mutate(data.frame(a = numeric(0)), index = row_number())
## Error: upper value must be greater than lower value
mutate(data.frame(a = 1), index = row_number())
##   a index
## 1 1     1
@romainfrancois romainfrancois added the bug an unexpected problem or unintended behavior label Nov 11, 2014
@romainfrancois romainfrancois added this to the 0.4 milestone Nov 11, 2014
@romainfrancois romainfrancois self-assigned this Nov 11, 2014
romainfrancois added a commit that referenced this issue Nov 11, 2014
…cume_dist`

  handles data frames with 0 rows. closes #762.
@romainfrancois
Copy link
Member

Should be fixed now in the dev_0_4_0 branch.

@sbisaacson
Copy link
Author

Thank you for fixing this.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 10, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug an unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

2 participants