-
Notifications
You must be signed in to change notification settings - Fork 422
Closed
Labels
Description
Consider the following df:
ID d1 d2
1 G G
2 A G
3 A A
4 G A
5 NA NA
6 G G
When uniting d1 and d2:
tidyr::unite(df, new, d1, d2, remove = FALSE, sep = "")
Row 5 gives NANA instead of the expected NA
ID new d1 d2
1 1 GG G G
2 2 AG A G
3 3 AA A A
4 4 GA G A
5 5 NANA <NA> <NA>
6 6 GG G G
paulponcet, tchakravarty, cchng, chris-s-friedman, epruesse and 4 more