code: def setGroupingActive(self, state, autoRefresh=False):
          
          self._groupingActive = state
          
          self.setRootIsDecorated(state)
          
          if autoRefresh:
              self.refresh()
docs: Sets whether or not grouping is enabled for this system.
          
          :param      state | <bool>