fix example & typo in multigroup function