def test_convolve_regressors(): # tests for convolve_regressors helper function conditions = ['c0', 'c1'] onsets = [20, 40] paradigm = pd.DataFrame({'name': conditions, 'onset': onsets}) # names not passed -> default names frame_times = np.arange(100) f, names = _convolve_regressors(paradigm, 'canonical', frame_times) assert_equal(names, ['c0', 'c1'])
def test_convolve_regressors(): # tests for convolve_regressors helper function conditions = ["c0", "c1"] onsets = [20, 40] paradigm = pd.DataFrame({"name": conditions, "onset": onsets}) # names not passed -> default names frame_times = np.arange(100) f, names = _convolve_regressors(paradigm, "glover", frame_times) assert_equal(names, ["c0", "c1"])
def test_convolve_regressors(): # tests for convolve_regressors helper function conditions = ['c0', 'c1'] onsets = [20, 40] duration = [1, 1] events = pd.DataFrame( {'trial_type': conditions, 'onset': onsets, 'duration': duration}) # names not passed -> default names frame_times = np.arange(100) f, names = _convolve_regressors(events, 'glover', frame_times) assert_equal(names, ['c0', 'c1'])