`dplyr::full_join()`donds';不能使用列表列
我试图比较R包`dplyr::full_join()`donds';不能使用列表列,r,dplyr,tidyverse,tidy,R,Dplyr,Tidyverse,Tidy,我试图比较R包ggstatsplot中给定函数的两个版本的形式。我已经能够在tibbles中提取形式,但我似乎无法将这两个表连接起来dplyr::full_join()会产生一个错误,但并不清楚它会导致什么。如果您对我如何加入这两个数据帧有任何反馈,我将不胜感激 #设置 种子集(123) 图书馆(tidyverse) 图书馆(ggstatsplot) #函数的主要版本的形式 (df_小学% dplyr::rename(.data=,primary=value)) #>#A tibble:41 x
ggstatsplot
中给定函数的两个版本的形式。我已经能够在tibbles中提取形式,但我似乎无法将这两个表连接起来dplyr::full_join()
会产生一个错误,但并不清楚它会导致什么。如果您对我如何加入这两个数据帧有任何反馈,我将不胜感激
#设置
种子集(123)
图书馆(tidyverse)
图书馆(ggstatsplot)
#函数的主要版本的形式
(df_小学%
dplyr::rename(.data=,primary=value))
#>#A tibble:41 x 2
#>名称主要
#>
#>1数据
#>2 x
#>3箱宽
#>4巴
#>5 xlab
#>6标题
#>7副标题
#>8标题
#>9型
#>10.测试值
#> # ... 还有31行
#函数的分组版本的形式
(df_%分组)
dplyr::重命名(.data=,grouped=value))
#>#A tibble:43 x 2
#>名称分组
#>
#>1数据
#>2 x
#>3.var
#>4.标题前缀
#>5箱宽
#>6巴
#>7 xlab
#>8副标题
#>9标题
#>10型
#> # ... 还有33排
#连接两个数据帧名称
dplyr::完全连接(
x=df_主,
y=df_分组,
by=“name”
)
#>错误:类型不受支持
回溯
#>4:停止(列表(message=“type not supported”,call=NULL,cppstack=NULL))
#>3:full_join_impl(x,y,by_x,by_y,aux_x,aux_y,na_matches,environment())
#>2:full_join.tbl_df(x=tibble::enframe(formals(ggstatsplot::gghistorstats))%>%
#>dplyr::rename(.data=,primary=value),y=tibble::enframe(formals(ggstatsplot::groupedgghistorstats))%>%
#>dplyr::rename(.data=,grouped=value),by=“name”)
#>1:dplyr::full_join(x=tibble::enframe(formals(ggstatsplot::gghistorstats))%>%
#>dplyr::rename(.data=,primary=value),y=tibble::enframe(formals(ggstatsplot::groupedgghistorstats))%>%
#>dplyr::rename(.data=,grouped=value),by=“name”)
由(v0.2.1)创建于2019-01-25,似乎不支持点对类型。有一件事,我们可以把它转换成一个普通的
列表
,然后进行完全连接
formals(ggstatsplot::gghistostats) %>%
as.list %>%
tibble::enframe(value = 'primary') %>%
full_join(formals(ggstatsplot::grouped_gghistostats) %>%
as.list %>%
tibble::enframe(value = 'grouped'))
# A tibble: 40 x 3
# name primary grouped
# <chr> <list> <list>
# 1 data <NULL> <missing>
# 2 x <missing> <missing>
# 3 binwidth <NULL> <NULL>
# 4 bar.measure <chr [1]> <chr [1]>
# 5 xlab <NULL> <NULL>
# 6 title <NULL> <NULL>
# 7 subtitle <NULL> <NULL>
# 8 caption <NULL> <NULL>
# 9 type <chr [1]> <chr [1]>
#10 test.value <dbl [1]> <dbl [1]>
# … with 30 more rows
formals(ggstatsplot::gghistorstats)%>%
as.list%>%
TIBLE::enframe(值='primary')%>%
完全联接(形式(ggstatsplot::groupedgghistorstats)%>%
as.list%>%
tibble::enframe(值='grouped'))
#一个tibble:40x3
#名称主要分组
#
#1数据
#2 x
#3箱宽
#4巴
#5 xlab
#6标题
#7副标题
#8标题
#9型
#10.测试值
#…还有30行
什么是点对
?@indrajeetpail。它是根据formals
创建的类型,即formals(lm)%%>%str#14个点对列表