> I need to calculate the mean of a variable for a subset of the data.
> It does not seem that the mean functions allows the "subset=" option.
> Does anyone know how I might accomplish this.
You can put the subsetting expression within the call to mean as in
mean( x[ x > 5 ] )