most of this section looks like it could be refactored out to a function in the ``Groupby`` object and just called (from ``NDFrameGroupby`` and the ``Groupby`` to avoid the code dup? (for the transform/filter) cases