Hi,
Thanks to everyone working on tibble, dplyr, tidyr... In general the tidyverse packages make a lot of people very happy to use R.
I have found a rather simple case where dplyr::combine fails, and the do.call rbind equivalent works as expected. I have tested this on the latest released dplyr and the current master (b205d1f) versions, both showing the same error. I found this error trying to unnest a data frame using tidyr, but my C++ skills and dplyr knowledge are not good enough to fix it.
library(dplyr)
do.call(rbind,list("a", "b", "c", NA, "e")) # Works
combine(list("a", "b", "c", NA, "e")) # Does not work
#Error in eval(substitute(expr), envir, enclos) :
# Can not automatically convert from character to logical.
combine(list("a", "b", "c", NA_character_, "e")) # Workaround
This issue affects unnest in tidyr:
library(tibble)
library(tidyr)
aa <- tibble(ID = list("a", "b", "c", NA, "e"))
bb <- unnest_(aa, "ID") # I would expect bb == tibble(ID = c("a", "b", "c", NA, "e"))
Any help will be appreciated
Hi,
Thanks to everyone working on tibble, dplyr, tidyr... In general the tidyverse packages make a lot of people very happy to use R.
I have found a rather simple case where
dplyr::combinefails, and the do.call rbind equivalent works as expected. I have tested this on the latest released dplyr and the current master (b205d1f) versions, both showing the same error. I found this error trying to unnest a data frame using tidyr, but my C++ skills and dplyr knowledge are not good enough to fix it.This issue affects
unnestin tidyr:Any help will be appreciated