Open adam2392 opened 2 years ago
@adam2392 I think you need to go deeper and make this a change in mne
itself.
More specifically I think one could add a method like replace_data
to BrowserBase
.
You would have to consider all relevant data-attributes like e.g. self._data
and self._times
and make it work for all possible data-instances (raw
, epochs
, ica
).
Then you might want to refresh the view and set the time-back to 0. For qt-backend this would look something like this:
self.mne.t_start = 0
self.mne.plt.setXRange(self.mne.t_start, self.mne.t_start + self.mne.duration)
Is your feature request related to a problem? Please describe. I would like to be able to use the
mne-qt-browser
and dynamically replace the trace (raw or ica) that is visualized. For example, I would like to plot the raw EEG or ica source based on which channel/component is selected by the user.Describe the solution you'd like @marsipu thanks for your help so far. Are you able to point out what changes you think will be needed in order for this refactoring to be enabled?
Additional context Discussion came up in: https://mne.discourse.group/t/embedding-time-series-plot-of-mne-qt-browser-into-our-own-gui/5090/10?u=adam2392