Replace p.min function with f.cmp

f.cmp is a more general function for finding stats by region.  The
arguments are a DataFrame, columname and function.  f.cmp then
performs the function over the set of components in each region. f.cmp
returns a DataFrame.