proper docstring for group function