Remove nodes and edges from tree if they are not the ingroup or a descendant of it.

def prune_to_ingroup(self):
        """Remove nodes and edges from tree if they are not the ingroup or a descendant of it."""
        # Prune to just the ingroup
        if not self._ingroup_node_id:
            _LOG.debug('No ingroup node was specified.')
            self._ingroup_node_id = self.root_node_id
        elif self._ingroup_node_id != self.root_node_id:
            self._do_prune_to_ingroup()
            self.root_node_id = self._ingroup_node_id
        else:
            _LOG.debug('Ingroup node is root.')
        return self.root_node_id