Count number of records in data.frame:
resultDf <- data.frame(table(df$colName))
Intersection of two data.frame:
resultDf <- merge(x=df1, y=df2, by=c("common_column_name"))
Union of two data.frame:
resultDf <- merge(x=df1, y=df2, by=c("common_column_name"), all=TRUE)
Exclusion of two data.frame: (record values in dfa but not in dfb)
resultDf <- dfa[!(dfa$colValue %in% dfb$colValue),]
Compute values by levels:
resultDf <- aggregate(df$colValue, list(df$colName), max) resultDf <- aggregate(df$colValue, list(df$colName), mean)