I have a column of sites: [\'Canada\', \'USA\', \'China\' ....]
Each site occurs many times in the SITE column and next to each instance is a true or false value.
Something like this:
In [13]: g = df.groupby('SITE')['VALUE'].mean() In [14]: g[g > 0.1] Out[14]: SITE Canada 0.5 USA 1.0