我想将该数据帧转换为mids以继续我的分析,但是我收到了一个错误,我无法找到帮助。
以下是数据框的一瞥:
> head(Imp5N2NPV4_2_17)
# A tibble: 6 × 137
Imputation_ ID Site Subject DateSOPS DateNP DaysNPfromSOPS Visit TypeConvNon TypeCtPr TypeName
<dbl+lbl> <dbl> <dbl> <dbl> <date> <date> <dbl> <dbl> <dbl+lbl> <dbl+lbl> <chr>
1 0 1001 1 1 2009-03-09 2009-03-13 4 1 0 1 Prodromal
2 0 1001 1 1 2009-03-09 <NA> NaN 2 0 1 Prodromal
3 0 1001 1 1 2009-03-09 <NA> NaN 3 0 1 Prodromal
4 0 1001 1 1 2009-03-09 <NA> NaN 4 0 1 Prodromal
5 0 1002 1 2 2009-01-05 2009-04-17 102 1 0 1 Prodromal
6 0 1002 1 2 2009-01-05 <NA> NaN 2 0 1 Prodromal
# ... with 125 more variables: Type3gp <dbl+lbl>, CHR_converter <dbl+lbl>, Age.SOPS <dbl>, age_ym <dbl>, sex <dbl>,
以下是代码:
Imp5N2NPV4_2_17<-as.mids(Imp5N2NPV4_2_17,.imp = 1, .id = 2)
这是我不明白的错误:
row.names&lt; - 。data.frame( tmp ,value = value)出错: 无效&#39; row.names&#39;长度
感谢您的帮助