【发布时间】:2020-02-15 05:24:36
【问题描述】:
在dplyr 包中使用mutate_at() 时收到一条警告消息。
dt %>%
mutate_at(
c(5:43),
funs(pc = ./Population)
)
Warning message:
funs() is soft deprecated as of dplyr 0.8.0
Please use a list of either functions or lambdas:
# Simple named list:
list(mean = mean, median = median)
# Auto named with `tibble::lst()`:
tibble::lst(mean, median)
# Using lambdas
list(~ mean(., trim = .2), ~ median(., na.rm = TRUE))
This warning is displayed once per session.
还有其他功能吗?
如何使用data.table 传递它。
【问题讨论】:
标签: r dplyr data.table data-manipulation