Use ddply within a function and include variable of interest as an argument

前端 未结 4 1134
南方客
南方客 2020-12-30 13:24

I am relatively new to R, and trying to use ddply & summarise from the plyr package. This post almost, but not quite, answers my question. I could use some additional ex

4条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-30 13:49

    Just use as.quoted function. Example below

    simple_ddply <- function(dataset_name, variable_name){
        data <- ddply(dataset_name,as.quoted(variable_name), *remaining input)**
    

提交回复
热议问题