meanTraitFunc function

calculate the mean trait at the end of the model run