Alright, this should be an easy one but I\'m looking for a solution that\'s as fast as possible.
Let\'s say I have 3 tables (the number of tables will be much larger
you can try this
df <- rbind(as.matrix(tab1), as.matrix(tab2), as.matrix(tab3)) aggregate(df, by=list(row.names(df)), FUN=sum) Group.1 V1 1 1 7 2 2 3 3 3 4 4 4 3 5 5 1