Azzera filtri
Azzera filtri

Imaginary part of mscohere

5 visualizzazioni (ultimi 30 giorni)
Eric
Eric il 8 Mar 2015
Commentato: David Haslacher il 28 Lug 2017
Hi everybody,
Is there a way to extract the imaginary part of the coherence when using mscohere? I can't find the original code anywhere. It seems to be protected by MATLAB.
I'm very interested in using the Welch method.
Best,
Eric

Risposte (1)

Christiaan
Christiaan il 10 Mar 2015
Modificato: Christiaan il 10 Mar 2015
Dear Eric,
The formula for the Magniture Squared Coherence can be found here. Pxx and Pyy are the power spectral densities of the signals x and y. (PSD of Autocorrelation) These two quantities are real and positive. The magnitude of the cross power spectral density is (as any magnitude of complex numbers) also real and positive. Therefore you can from definition not extract a 'complex part of the MSC'.
If you still interested in the background of the mscohere function, you can type in the matlab prompt:
edit mscohere
Then you can find that the mscohere function uses the welch function. Since the function is private type in:
which welch -all
Now you have found the folder where the welch function is defined. The last step is to type in edit('.....link of previous output') and look at 'case 'mscohere'.
Good luck! Christiaan
Kind regards, Christiaan
  1 Commento
David Haslacher
David Haslacher il 28 Lug 2017
I would wager that he's talking about coherency, Cab/sqrt(Caa * Cbb), which is complex [1]. Coherence is then the modulus of coherency.
Nolte G., Bai O., Wheaton L., Mari Z., Vorbach S., Hallett M. (2004). Identifying true brain interaction from EEG data using the imaginary part of coherency. Clin. Neurophysiol. 115, 2292–2307. 10.1016/j.clinph.2004.04.029 [PubMed] [Cross Ref]

Accedi per commentare.

Categorie

Scopri di più su Signal Generation and Preprocessing in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by