# ICA with existing unmixing matrix

**URL:** <https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621>\
**Category:** Support & Discussions\
**Tags:** ica\
**Created:** [September 22, 2022, 6:19pm UTC](https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621 "2022-09-22T18:19:15Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hhdd](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/hhdd/32/1917_2.png) [@hhdd](https://mne.discourse.group/u/hhdd)\
**Post date:** [September 22, 2022, 6:19pm UTC](https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621/1 "2022-09-22T18:19:16Z")

</div>

- MNE version: 1.1.1
- operating system: macOS 12.6

I want to apply ICA to my EEG dataset with an existing unmixing matrix, i.e., I don’t want to use the unmixing matrices in the ICA method itself. Is there a way I can read in a pre-existing unmixing matrix through `.ICA` or related functions?

Context: I am replicating data preprocessing done in matlab through MNE.

---

<div class="post-metadata">

**Author:** ![mscheltienne](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/mscheltienne/32/827_2.png) [@mscheltienne](https://mne.discourse.group/u/mscheltienne)\
**Post date:** [September 22, 2022, 6:49pm UTC](https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621/2 "2022-09-22T18:49:02Z")

</div>

If you used EEGLAB, you can load an ICA decomposition in MNE with [mne.preprocessing.read\_ica\_eeglab — MNE 1.1.1 documentation](https://mne.tools/stable/generated/mne.preprocessing.read_ica_eeglab.html?highlight=read_ica#mne.preprocessing.read_ica_eeglab)

---

<div class="post-metadata">

**Author:** ![hhdd](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/hhdd/32/1917_2.png) [@hhdd](https://mne.discourse.group/u/hhdd)\
**Post date:** [September 23, 2022, 1:03am UTC](https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621/3 "2022-09-23T01:03:12Z")

</div>

The existing unmixing matrix is in fieldtrip, so there isn’t an object that has the required extension. Is there a generic version of this function?

---

<div class="post-metadata">

**Author:** ![mscheltienne](https://yyz2.discourse-cdn.com/free1/user_avatar/mne.discourse.group/mscheltienne/32/827_2.png) [@mscheltienne](https://mne.discourse.group/u/mscheltienne)\
**Post date:** [September 23, 2022, 7:48am UTC](https://mne.discourse.group/t/ica-with-existing-unmixing-matrix/5621/4 "2022-09-23T07:48:24Z")

</div>

Not to my knowledge, but I think you could write your own function by adapting the code of `read_ica_eeglab`. See: [mne-python/ica.py at maint/1.1 · mne-tools/mne-python · GitHub](https://github.com/mne-tools/mne-python/blob/maint/1.1/mne/preprocessing/ica.py#L2794-L2856)
