<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Helvetica;
        panose-1:2 11 6 4 2 2 2 2 2 4;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Mistral;
        panose-1:3 9 7 2 3 4 7 2 4 3;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
        {font-family:"Arial Nova";}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
span.apple-converted-space
        {mso-style-name:apple-converted-space;}
span.EmailStyle19
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="SV" link="blue" vlink="purple" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US">Hi, <o:p>
</o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US">I indeed wish to calculate the power spectral density of my signal. I.e., how the signal power is distributed across various frequencies. Fieldtrip’s ft_freqanalysis function can indeed
 calculate this (even though they do not explicitly use this term. <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg              = [];<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg.method       =
<span style="color:#A709F5">'mtmfft'</span>;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg.taper        =
<span style="color:#A709F5">'dpss'</span>;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg.tapsmofrq       = 0.5;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg.output       =
<span style="color:#A709F5">'pow'</span>;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">    cfg.channel = {<span style="color:#A709F5">'F3'</span>,
<span style="color:#A709F5">'Fz'</span>, <span style="color:#A709F5">'F4'</span>};
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.0pt;font-family:Consolas">  theta_freq) = ft_freqanalysis(cfg, ft_data);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US">Now, while power is generally represented in Watt, a common unit of power is
</span><span lang="EN-GB">are µV^2/Hz. This however is not the output that I get, but seems to be smaller by a factor of ~120. As I wish to publish in accordance with the convention, I at least wish to know what type of normalization/transformation Fieldtrip
 is performing and what the rationale for that is. <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:16.0pt;font-family:Mistral">/Adam</span><span lang="EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">______________________________________________________________________________________</span><span lang="EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Adam Grinberg, PT, PhD</span><span lang="EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Department of Community Medicine and Rehabilitation, Physiotherapy</span><span lang="EN-GB"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Umeå University<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Umeå, Sweden<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Tel: +46 (0) 90 786 96 30<o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span lang="EN-GB" style="mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US">From:</span></b><span lang="EN-US"> fieldtrip <fieldtrip-bounces@science.ru.nl>
<b>On Behalf Of </b>Schoffelen, J.M. (Jan Mathijs) via fieldtrip<br>
<b>Sent:</b> 11 April 2023 17:09<br>
<b>To:</b> FieldTrip discussion list <fieldtrip@science.ru.nl><br>
<b>Cc:</b> Schoffelen, J.M. (Jan Mathijs) <janmathijs.schoffelen@donders.ru.nl><br>
<b>Subject:</b> Re: [FieldTrip] PSD units<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Hi Adam, <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">What’s your question? I have some difficulty distilling it from your e-mail. <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">I assume that you have visited the discussion list’s archive, where you will have noticed that questions regarding the units of the output of ft_freqanalysis pop up now and then. <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Nobody seems to have made an effort so far, to sort it out once and for all, by making a FAQ out of this. I think it would be great if you could start this piece of documentation by describing the normalisation that FT
 uses in ft_freqanalysis (and the underlying ft_specest_<> functions), and how this relates to plain matlab, or any other software package. <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Perhaps you could start by studying the difference between the power spectrum, and power spectral density. The fact that you use the term PSD in your e-mail, whereas - as far as I know - fieldtrip does not use this terminology,
 nor claims that it computes the PSD. <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Good luck,<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Jan-Mathijs<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span lang="EN-GB"><br>
<br>
<o:p></o:p></span></p>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal"><span lang="EN-GB">On 11 Apr 2023, at 09:09, Adam Grinberg via fieldtrip <</span><a href="mailto:fieldtrip@science.ru.nl"><span lang="EN-GB">fieldtrip@science.ru.nl</span></a><span lang="EN-GB">> wrote:<o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Hello,<span class="apple-converted-space"> </span><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">My question concerns the Fieldtrip PSD function. I am running the code on some EEG data and comparing it with the MATLAB periodogram function. While the FFT produces similar graphical shape of the spectrogram, the units
 are different.<span class="apple-converted-space"> </span><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">The periodogram function’s units are µV^2/Hz, which is the common output for power (before converting to Db). However, the values that I get with the Fieldtrip freqanalysis function seem to be ~120 times lower. I cannot
 understand what they are. I looked at the code and still do not get it. I suppose that this is due to some normalization method done but I am not certain as to the rationale for the particular one used.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB">Tanks.<o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"> <o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:16.0pt;font-family:Mistral">/Adam</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">______________________________________________________________________________________</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Adam Grinberg, PT, PhD</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Department of Community Medicine and Rehabilitation, Physiotherapy</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Umeå University</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Umeå, Sweden</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB" style="font-family:"Arial Nova",sans-serif;color:#7F7F7F">Tel: +46 (0) 90 786 96 30</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><span lang="EN-GB"> <o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span lang="EN-GB" style="font-size:10.5pt;font-family:"Helvetica",sans-serif">_______________________________________________<br>
fieldtrip mailing list<br>
</span><a href="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip"><span lang="EN-GB" style="font-size:10.5pt;font-family:"Helvetica",sans-serif">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</span></a><span lang="EN-GB" style="font-size:10.5pt;font-family:"Helvetica",sans-serif"><br>
</span><a href="https://urldefense.com/v3/__https://doi.org/10.1371/journal.pcbi.1002202__;!!HJOPV4FYYWzcc1jazlU!5RV3s_lQGO_tsuGgo7zcEBucW8cr1i6mPkGsevulfd0lqL2ZKYY1PEjFVCEckP4wN0npvpixDOgKahPY-LyhBMYq7EeOEcRI1EwbUA$"><span lang="EN-GB" style="font-size:10.5pt;font-family:"Helvetica",sans-serif">https://urldefense.com/v3/__https://doi.org/10.1371/journal.pcbi.1002202__;!!HJOPV4FYYWzcc1jazlU!5RV3s_lQGO_tsuGgo7zcEBucW8cr1i6mPkGsevulfd0lqL2ZKYY1PEjFVCEckP4wN0npvpixDOgKahPY-LyhBMYq7EeOEcRI1EwbUA$</span></a><span lang="EN-GB"><o:p></o:p></span></p>
</div>
</blockquote>
</div>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
</div>
</div>
</body>
</html>