How to group a unique column and find the mean value in a separate column in R My table of data looks like this image (but with many more lines):

 

I want to be able to find the mean age of each region, so the mean age for region SSC20790 and so on. I believe I can use the dplyr package?
Something like this for instance:

library(plyr)
ddply(data,'region',function(x) {mean(x$age)})