A simpler way to achieve a frequency count with mean, sum, length and sd in R
问题 I've been tasked with creating frequency tables with statistical summaries. My goal is to create a data frame that can be exported simply to excel. Most of this could be in sql using stored procedures but I decided to do this in R. I'm learning R so I might be doing it the long way. This is a follow on question from getting-r-frequency-counts-for-all-possible-answers Given Id <- c(1,2,3,4,5,6,7,8,9,10) ClassA <- c(1,NA,3,1,1,2,1,4,5,3) ClassB <- c(2,1,1,3,3,2,1,1,3,3) R <- c(1,2,3,NA,9,2,4,5