From beba317c53d1d4d2f5b64ecd4b1e303632d537d7 Mon Sep 17 00:00:00 2001 From: Adina Wagner Date: Thu, 24 Jan 2019 17:07:59 -0500 Subject: [PATCH] BF: run_info is the third positional argument. Otherwise it was passing 'events' string when applying Split transformation. --- bids/variables/variables.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/bids/variables/variables.py b/bids/variables/variables.py index d314bd70b..0f98548bb 100644 --- a/bids/variables/variables.py +++ b/bids/variables/variables.py @@ -253,9 +253,7 @@ def split(self, grouper): subsets = [] for i, (name, g) in enumerate(data.groupby(grouper)): name = '%s.%s' % (self.name, name) - args = [name, g, self.source] - if hasattr(self, 'run_info'): - args.append(self.run_info) + args = [name, g, getattr(self, 'run_info', None), self.source] col = self.__class__(*args) subsets.append(col) return subsets