title: Applying grouping to values greater than average
body: <p>I have a vector where I want to group based on the rolling average of the values in my vector.  If the values are greater than average than I place them in group 1, if they are less they go in group 2.</p>
  
  <p>What function can be used to give a group number to each to value within my vector based on whether or not its value is greater than the current average.</p>