I have a dataset containing 100000 rows of data. I tried to do some countif operations in Excel, but it was prohibitively slow. So I am wondering if this kind o
countif
library(matrixStats) > data <- rbind(c("M", "F", "M"), c("Student", "Analyst", "Analyst")) > rowCounts(data, value = 'M') # output = 2 0 > rowCounts(data, value = 'F') # output = 1 0