You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unnest refuses to process data frames with syntactically invalid column names (e.g. containing spaces or beginning with numbers):
library(dplyr)
library(tidyr)
dat <- data.frame("foo bar" = I(list(1:2, 3)), check.names = F)
unnest(dat)
# Error in parse(text = x) : <text>:1:5: unexpected symbol
#1: foo bar
# ^
unnest_(dat, names(dat))
# Error in parse(text = x) : <text>:1:5: unexpected symbol
#1: foo bar
# ^
dat %>% rename(foobar=`foo bar`) %>% unnest
# Source: local data frame [3 x 1]
#
# foobar
# (dbl)
#1 1
#2 2
#3 3
I don't know if it's a bug or if I'm using the function wrongly, but I think it worked in previous versions of tidyr. I'm packageVersion("tidyr") ‘0.4.1’ and packageVersion("dplyr") ‘0.4.3’
The text was updated successfully, but these errors were encountered:
unnest
refuses to process data frames with syntactically invalid column names (e.g. containing spaces or beginning with numbers):I don't know if it's a bug or if I'm using the function wrongly, but I think it worked in previous versions of
tidyr
. I'mpackageVersion("tidyr")
‘0.4.1’ andpackageVersion("dplyr")
‘0.4.3’The text was updated successfully, but these errors were encountered: