<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Hi Jan,</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Thanks for this added info. This (<span style="font-size:14px; background-color:rgb(255,255,255); display:inline!important">ft_channelnormalise)</span> appears like a good function for my power analysis because it provides the perchannel vs across channel added
 option. I have not been sure in brainstorm whether the baseline values being used as input to z-transform was derived from all channels or per respective channel.  I think 'all channels' will be more appropriate as I am looking at abrupt discharges which dont
 necessarily channel by channel follow the resting state baseline rhythm variation. For example frontal regions have more faster lower amplitude but the discharges of my interest have higher amplitude frontally. Makes it tricky. </div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
I see however there is no segment definition input in this function for baseline selection which makes preproc_standardize good. My understanding was that baseline for transforming is always better selected 'out of' the segment to be analysed. I will test and
 try and see both functions. </div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Regards,</div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Mubeen</div>
<div>
<div id="appendonsend"></div>
<div style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> fieldtrip <fieldtrip-bounces@science.ru.nl> on behalf of Schoffelen, J.M. (Jan Mathijs) <jan.schoffelen@donders.ru.nl><br>
<b>Sent:</b> Sunday, March 28, 2021 5:23 PM<br>
<b>To:</b> FieldTrip discussion list <fieldtrip@science.ru.nl><br>
<b>Subject:</b> Re: [FieldTrip] baseline normalizing</font>
<div> </div>
</div>
<div class="" style="word-wrap:break-word; line-break:after-white-space">Just one addition to Tzvetan’s reply, just for future reference:
<div class=""><br class="">
</div>
<div class="">ft_preproc_standardize is a rather ‘low-level’ function, and not recommended unless you know what you’re doing.</div>
<div class="">For your purpose you probably want to use ft_channelnormalise or ft_denoise_prewhiten. Which of the two depends on what you think is happening in Brainstorm. Note that the former (i.e. ft_channelnormalise) only scales the data (and the resulting
 power spectra if you proceed with spectral analysis), so it is not  really clear what you intend to achieve.</div>
<div class=""><br class="">
</div>
<div class="">Best wishes,</div>
<div class="">Jan-Mathijs</div>
<div class="">
<div><br class="">
<blockquote type="cite" class="">
<div class="">On 28 Mar 2021, at 15:52, mubeen afzal <<a href="mailto:mubafzal@hotmail.com" class="">mubafzal@hotmail.com</a>> wrote:</div>
<br class="x_Apple-interchange-newline">
<div class="">
<div class="" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Calibri,Helvetica,sans-serif; font-size:12pt">
Ahh perfect Tzvetan. Thanks  alot for the quick reply. This function is good to transform the time series data. </div>
<div class="" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Calibri,Helvetica,sans-serif; font-size:12pt">
<br class="">
</div>
<div class="" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Calibri,Helvetica,sans-serif; font-size:12pt">
Regards,</div>
<div class="" style="font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; font-family:Calibri,Helvetica,sans-serif; font-size:12pt">
Mubeen</div>
<div class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<div id="x_appendonsend" class=""></div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><br class="">
</div>
<hr tabindex="-1" class="" style="display:inline-block; width:1635.609375px">
<div id="x_divRplyFwdMsg" dir="ltr" class=""><font face="Calibri, sans-serif" class="" style="font-size:11pt"><b class="">From:</b><span class="x_Apple-converted-space"> </span>fieldtrip <<a href="mailto:fieldtrip-bounces@science.ru.nl" class="">fieldtrip-bounces@science.ru.nl</a>>
 on behalf of Tzvetan Popov <<a href="mailto:tzvetan.popov@uni-konstanz.de" class="">tzvetan.popov@uni-konstanz.de</a>><br class="">
<b class="">Sent:</b><span class="x_Apple-converted-space"> </span>Sunday, March 28, 2021 10:48 AM<br class="">
<b class="">To:</b><span class="x_Apple-converted-space"> </span>FieldTrip discussion list <<a href="mailto:fieldtrip@science.ru.nl" class="">fieldtrip@science.ru.nl</a>><br class="">
<b class="">Subject:</b><span class="x_Apple-converted-space"> </span>Re: [FieldTrip] baseline normalizing</font>
<div class=""> </div>
</div>
<div dir="auto" class="">
<div dir="ltr" class="">Dear Mubeen,</div>
<div dir="ltr" class="">The function you intend to use requires time dimension. What you provide is only power spectrum. </div>
<div dir="ltr" class="">You could use <a href="https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.fieldtriptoolbox.org%2Freference%2Fft_preproc_standardize%2F&data=04%7C01%7C%7C50500c0f02d049d45c2308d8f1f84540%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637525396099670134%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=ts%2Fb%2BIy0goudTeiglpck7bhc0c7HaKmwMmAVUlsqR34%3D&reserved=0" originalsrc="https://www.fieldtriptoolbox.org/reference/ft_preproc_standardize/" shash="cyuYsV3A0iNC0wqmLjgJrtuXHl1oR9t6j98B25frxym4C/yjORnqHMtb5Wr5ivqRyTLOxsEC7RzHCRa/W/nIz3vsKUC2zhKu1CSUIjpYUrKJjuocjbhruBOAfceqlRzAlkB10GJVGuC3BDousxtRWvuCdtzoGHRicNrwZMGxSzI=" class="">https://www.fieldtriptoolbox.org/reference/ft_preproc_standardize/</a> prior
 to your freqanalysis if standardized z-scores is what you need. </div>
<div dir="ltr" class=""><br class="">
</div>
<div dir="ltr" class="">Good luck,</div>
<div dir="ltr" class="">Tzvetan</div>
<div dir="ltr" class=""><br class="">
</div>
<div dir="ltr" class=""><br class="">
<blockquote type="cite" class="">Am 3/28/21 um 07:16 schrieb mubeen afzal <<a href="mailto:mubafzal@hotmail.com" class="">mubafzal@hotmail.com</a>>:<br class="">
<br class="">
</blockquote>
</div>
<blockquote type="cite" class="">
<div dir="ltr" class="">
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">
<pre class="">Hi all,</pre>
<pre class=""><span class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">In brainstorm there is option of baseline normalizing (zscore or db or other methods) the timeseries epochs/trials of interest before frequency analysis allowing visual comparisons and further frequency analysis of the normalized epochs</span><br class=""></pre>
<pre class="">The normalization function function [freq] = ft_freqbaseline(cfg, freq) doesnt allow normalizing a freq output dimord structure with chan_freq derived using 'mtmfft' method</pre>
<pre class=""></pre>
I get this error message - </div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><i class=""><br class="">
</i></div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><i class="">"the call to "ft_freqanalysis" took 1 seconds</i>
<div class=""><i class="">the input is freq data with 21 channels, 191 frequencybins and no timebins</i></div>
<div class=""><i class="">Error using ft_freqbaseline (line 146)</i></div>
<i class="">unsupported data dimensions: chan_freq"</i></div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><br class="">
</div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">Is there a way around this?</div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><br class="">
</div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">Thanks all.</div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt"><br class="">
</div>
<div class="" style="font-family:Calibri,Helvetica,sans-serif; font-size:12pt">Mubeen</div>
<span class="">_______________________________________________</span><br class="">
<span class="">fieldtrip mailing list</span><br class="">
<span class=""><a href="https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmailman.science.ru.nl%2Fmailman%2Flistinfo%2Ffieldtrip&data=04%7C01%7C%7C50500c0f02d049d45c2308d8f1f84540%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637525396099670134%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=6y%2FzHGX3EQBZPsalb6FXkV4wOI2OYZmh7Ux%2FZt5EfGI%3D&reserved=0" originalsrc="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip" shash="TYANZ8SKi/ab5RiN1WqvZ4Z5sCraqx/OLtnNJyVx+gPmpv/OEAcL6CAfdnqI5Z+AnIlUZ+ofXc4ANsYnTvt0t6rr33NN5u9cbnHmP6x05a2cxpuuu7/DGK4UkTV5ZdOGZTEHo5hiU+WEYE2FCruM5hBMI//VYqOssEgraF5iZnI=" class="">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a></span><br class="">
<span class=""><a href="https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdoi.org%2F10.1371%2Fjournal.pcbi.1002202&data=04%7C01%7C%7C50500c0f02d049d45c2308d8f1f84540%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637525396099680128%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=qKKNDfZ%2F0lkA6EbyS6UlIxovyZbJxChWvhoFmOqG8uc%3D&reserved=0" originalsrc="https://doi.org/10.1371/journal.pcbi.1002202" shash="GwDtTf54tW9+EaOJnqPPkuNLgdX0aFsHmSdcw+smm5JE79McVO6XROg8y1PQQHCFTw1XEvNITsWZhtoPbzWBPjI8D3Fl2hTtAK4nFDjQbfL0GiGMGpDwVyU93Kg3IRUlsrz+sUuuiexsk9YN3K51/ev+j18EEEG5DTai4sc3R8E=" class="">https://doi.org/10.1371/journal.pcbi.1002202</a></span><br class="">
</div>
</blockquote>
</div>
</div>
<span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">_______________________________________________</span><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important">fieldtrip
 mailing list</span><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"><a href="https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmailman.science.ru.nl%2Fmailman%2Flistinfo%2Ffieldtrip&data=04%7C01%7C%7C50500c0f02d049d45c2308d8f1f84540%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637525396099680128%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=phOj4Fv8doFDlO5RVY44bO62qvwWsxqQdZwhKBYdN3Q%3D&reserved=0" originalsrc="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip" shash="ivU/VQ4PYhrFcqr47hrT13rzhxIu75koFKJPkbtRlFbMSjn7XfeRnRxU3HoPoB6JvfMmh3o4sf6/uf2LyqQ3CQs9I70rK+JFe1M4ukFCSyEX0e3Q3DITp7KktE2hXjicbn1NU4JAoC2V/rXr9vGTFZV8/OCMEUqzsjCw7P5hq50=" class="">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a></span><br class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none">
<span class="" style="font-family:Helvetica; font-size:14px; font-style:normal; font-variant-caps:normal; font-weight:normal; letter-spacing:normal; text-align:start; text-indent:0px; text-transform:none; white-space:normal; word-spacing:0px; text-decoration:none; float:none; display:inline!important"><a href="https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdoi.org%2F10.1371%2Fjournal.pcbi.1002202&data=04%7C01%7C%7C50500c0f02d049d45c2308d8f1f84540%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C637525396099690125%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=RIFEnbSuW2GrjxQr4kT3%2FeXyRufGG6Z4fNe23LUhwPw%3D&reserved=0" originalsrc="https://doi.org/10.1371/journal.pcbi.1002202" shash="EQ9aH9Kb8igQd7/f5D9voQJWVEXNmSLugwe4olFbyytZrX3vDVXZHrs6TI6rnaR2LoaGU5S9Ri4HdAxaw32Gnn76RMhXmx7FdTlcFfIrFsrge00o5w6Kuh1lpcjhhT4H3p6mknPhipBvuCUFfrvNCoCuS5gSx8gt7UqPuUHEWSw=" class="">https://doi.org/10.1371/journal.pcbi.1002202</a></span></div>
</blockquote>
</div>
<br class="">
</div>
</div>
</div>
</body>
</html>