Hi,
Basically I have an MNE RawArray object and I would like to convert it to
an ndarray.
I am doing an ICA of an EEG signal with 22 channels. I need an ndarray with
the corresponding time courses of the the Independent Components from the
ICA.
sources_raw = ica.get_sources(raw)
sources_array, times = sources_raw.get_data(return_times=True)
# PLOT THE NUMPY ARRAY OF SOURCES
fig, ax = plt.subplots()
# this will let us plot the sources without overlapping:
offsets = 15 * np.linspace(29, 0, len(sources_array))
ax.plot(times, sources_array.T + offsets, linewidth=0.5, color='k')
# COMPARE WITH THE MNE-PYTHON PLOT OF SOURCES
ica.plot_sources(raw)