Concatenate data before ICA

Dear Brainstorm community,

I have two links to raw MEG fiff files in my protocol, annotated for bad segments and preprocessed with some resampling/filtering.

I need to calculate ICA on this data concatenated: i.e: I would like to pass to the ICA the two datasets concatenated as a single one, preserving events and, ideally, marking the boundary of concatenation as bad segment.

Is this possible in Brainstorm by scripting ?

I’ve already tried to import data in database, concatenate them “manually” creating structures and correcting events. I’ve managed to get a correct result but I cannot feed anymore the imported data to the ICA process.

Any suggestion?

Thank you all and have a nice day !

Hello,

You can use the Process2 tab, select the input for the ICA algorithm on the left, and the files on which you want the apply the cleaning on the right.

Francois

Hi Francois,

thank you very much for your answer.

I apologize but maybe I didn’t explain very well what I want to do.
I don’t want to use a raw dataset (let say A) for calculating ICA projectors and the use them to clean another dataset (let say B).

I would like to calculate ICA projectors using [A B] as a unique data input to the ICA algorithm.

Do you think this is possible?

Thank you very much for your help !

D.

So put A+B on the left and A+B on the right.

Really cool! thanks (2 years later)

Is there a way to select the option “sort components based on correlation with (here i will use my HEOG)” because the option seem unavailable

Thanks!

I don’t think it is possible via the ICA pipeline. However, you can save the ICA component time series and compute the 1xn correlation of the ICA time series with HEOG using another the connectivity processing library in Brainstorm.

I simply had to add it as in the list of options of process_ica2:
https://github.com/brainstorm-tools/brainstorm3/commit/07a395450fffbc19ac7d3ef8b41c5c53c3770358#diff-7722f1ce59abe4a6f7a6ef43b6538450

The option should be available now.