About the transformation of matrix connections and non-parametric permutation test

Connectivity matrices are reshaped before saved in the TF field of the their .mat.

As such, if you want to carry out further processing outside of Brainstorm it is necessary to reshape them (connectivity matrix > TF field) and get them (TF > connectivity matrix). Check these posts about these links towards the documentation and related forum topics:

Documentation:
https://neuroimage.usc.edu/brainstorm/Tutorials/Connectivity#On_the_hard_drive

Related forum topics:

You need to use values make sense for the field Freqs in the custom connectivity file