rbind.na(row1,row2)中的错误:找不到函数“ rbind.na”

时间:2018-08-18 11:30:22

标签: r

rbind.na的软件包是什么?

我有一个简单的代码,例如:

row1 <- c("a","b","c","d")
row2 <- c("A", "B", "C")
row3 <- rbind.na(row1, row2)

但它抱怨:

Error in rbind.na(row1, row2) : could not find function "rbind.na"

那么rbind.na()的软件包是什么?

1 个答案:

答案 0 :(得分:0)

不需要任何程序包的Base R解决方案:

row1 <- c("a","b","c","d")
row2 <- c("A", "B", "C")
length(row2) <- length(row1)
row3 <- rbind(row1, row2)

或者,签出dplyr::bind_rows()