diff --git a/requirements/requirements.txt b/requirements/requirements.txt index 15075df..80ef4d4 100644 --- a/requirements/requirements.txt +++ b/requirements/requirements.txt @@ -1,5 +1,5 @@ neo>=0.9.0 -elephant>=0.9.0 +elephant>=0.14.0 numpy>=1.19.5 quantities>=0.14.1 matplotlib>=3.3.2 diff --git a/viziphant/unitary_event_analysis.py b/viziphant/unitary_event_analysis.py index c5a86bb..6139681 100644 --- a/viziphant/unitary_event_analysis.py +++ b/viziphant/unitary_event_analysis.py @@ -20,6 +20,8 @@ import matplotlib.pyplot as plt import string import elephant.unitary_event_analysis as ue +from elephant.trials import Trials +from elephant.utils import trials_to_list_of_spiketrainlist from collections import namedtuple FigureUE = namedtuple("FigureUE", ['axes_spike_events', @@ -58,7 +60,7 @@ 'suptitle': None, } - +@trials_to_list_of_spiketrainlist def plot_ue(spiketrains, Js_dict, significance_level=0.05, **plot_params): """ @@ -69,7 +71,7 @@ def plot_ue(spiketrains, Js_dict, significance_level=0.05, Parameters ---------- - spiketrains : list of list of neo.SpikeTrain + spiketrains : list of list of neo.SpikeTrain or :class:`elephant.trials.Trials` A nested list of trials, neurons and their neo.SpikeTrain objects, respectively. This should be identical to the one used to generate Js_dict.