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

in group_by, NA_character_ replaced by "" (empty string) #1839

Closed
bart6114 opened this issue May 19, 2016 · 4 comments
Closed

in group_by, NA_character_ replaced by "" (empty string) #1839

bart6114 opened this issue May 19, 2016 · 4 comments
Assignees
Labels
bug an unexpected problem or unintended behavior
Milestone

Comments

@bart6114
Copy link

relates to #1671

Apparently this bug is still here. Consider this adapted example from #1671:

test <- data.frame(id = rep(1:4, each = 3), grade = rep(c(NA, "a", NA, "b"), each = 3), stringsAsFactors = FALSE)

test %>% 
  group_by(id) %>% 
  dplyr::summarise(test = grade[1])

Results in:

     id  test
  (int) (chr)
1     1      
2     2     a
3     3    NA
4     4     b

Installing the latest dev version, as well as the suggested commit 9bae2aa, doesn't fix this issue.

@hadley hadley added bug an unexpected problem or unintended behavior data frame labels May 26, 2016
@hadley hadley added this to the 0.5 milestone May 26, 2016
@hadley
Copy link
Member

hadley commented May 26, 2016

You mean replaced by "", right? (in the title)

@bart6114 bart6114 changed the title in group_by, NA_character_ replaced by NA in group_by, NA_character_ replaced by "" (empty string) May 26, 2016
@bart6114
Copy link
Author

Ahum... Indeed, edited the title.

@hadley
Copy link
Member

hadley commented May 27, 2016

@romainfrancois can you take a look at this one too please?

@hadley hadley modified the milestones: future, 0.5 May 27, 2016
@soniampub
Copy link

@hadley I can look into this issue but I am a beginner to open source. If anyone can guide me here I would like to contribute more and more on dplyr. Please let me are there any other issues for beginner that you would like me to start on. I really appreciate your suggestions.

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

4 participants