首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >当我试图对从REDCap导出的数据进行撇除()时,Skimr错误消息

当我试图对从REDCap导出的数据进行撇除()时,Skimr错误消息
EN

Stack Overflow用户
提问于 2022-08-30 20:00:50
回答 1查看 23关注 0票数 0

我想使用skimr包和skim()函数来探索从REDCap导出的数据,但是它给了我这个错误消息。

代码语言:javascript
复制
Error in `dplyr::summarize()`:
! Problem while computing `skimmed = purrr::map2(...)`.
ℹ The error occurred in group 4: skim_type = "numeric".
Caused by error:
! Can't combine `..1$numeric.p0` <labelled> and `..2$numeric.p0` <labelled>.
✖ Some attributes are incompatible.
ℹ The author of the class should implement vctrs methods.
ℹ See <https://vctrs.r-lib.org/reference/faq-error-incompatible-attributes.html>.
Backtrace:
  1. skimr::skim(e2)
 10. purrr::map2(...)
 12. skimr:::skim_by_type.data.frame(.x[[1L]], .y[[1L]], ...)
 13. skimr:::build_results(skimmed, variable_names, NULL)
 15. tidyr:::unnest.data.frame(out, .data$by_variable)
     ...
 19. vctrs (local) `<fn>`()
 20. vctrs::vec_default_ptype2(...)
 21. vctrs::stop_incompatible_type(...)
 22. vctrs:::stop_incompatible(...)
 23. vctrs:::stop_vctrs(...)
 Error in dplyr::summarize(grouped, skimmed = purrr::map2(.data$skimmers, : 

ℹ The error occurred in group 4: skim_type = "numeric".
Caused by error:
! Can't combine `..1$numeric.p0` <labelled> and `..2$numeric.p0` <labelled>.
✖ Some attributes are incompatible.
ℹ The author of the class should implement vctrs methods.
ℹ See <https://vctrs.r-lib.org/reference/faq-error-incompatible-attributes.html>.
EN

回答 1

Stack Overflow用户

发布于 2022-11-08 20:00:06

之所以会发生这种情况,是因为这些数据都是类标记的。我必须更多地了解Redcap格式化的细节,但我建议,为了方便浏览,一个简单的解决方案是将其转换为标准的数据类型之一。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/73547866

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档