ica.get_sources has strange ch_names and ch_type
See original GitHub issueAfter calling ica.get_source()
with a Raw
object I noticed that
- the
ch_names
“ICA 001” start by 1 instead of 0 (which is not consistent) - I couldn’t plot it right, as the
ch_type
for scaling is not clear (it seems to bemisc
, but I couldn’t find any documentation about it)
I would suggest to let the ICAs start by 0 everywhere.
Remove the +1
here: https://github.com/mne-tools/mne-python/blob/master/mne/preprocessing/ica.py#L798
Issue Analytics
- State:
- Created 7 years ago
- Comments:13 (13 by maintainers)
Top Results From Across the Web
No results found
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
So over in #4320 the crushing weight of a half dozen (or more) opened issues/PRs about this issue has caused @agramfort to have a change of heart to accept the possibility of naming channels as
ICA 000
+. It creates inconsistency with other channel names, but IMO (and maybe @agramfort has come around to it, now, too) this is less bad / create fewer problems than our current solution, where most users are confused by our ICA interface.@dengemann @jona-sassenhagen @jasmainak @mmagnuski are you okay with this change?
@mmagnuski would you perhaps be up for making a PR?
I also think that ic numbering inconsistency is counterintuitive (and changing the docs won’t change the intuitions 😉 ).
ica.plot_sources
plots sources with names inIC #000
convention - which is good as it makes comparisons betweenplot_components
andplot_sources
easier, but further increases surprise whenica.get_sources().plot()
gives other labels (ICA 001
). If channel labels must of formICA 001
- then maybe ICA plotting functions should printICA 001
instead of the index? Or maybe both should change toIC 001
? 😈