<html><head><base href="x-msg://18/"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Alex,<div><br></div><div>just a very basic thought: Using a fixed zlim of [0 1] does not really make sense when using relative change (or absolute) baseline, as you could very well have values below zero post stimulus.</div><div>Also, when I compare your TFR Hanning (with absolute baseline) to the TFR Wavelet (with absolute baseline), they don't look too different, just badly scaled. Maybe you can play around with the zlim of the singleplot to get a better idea of what is happening here. Also, I wouldn't expect slightly different results from the wavelet vs. the mtmconvol as you are using different settings (e.g. 3 cycles width in the mtmconvol vs. 7 cycles in the wavelet).</div><div><br></div><div>Good luck,</div><div><br></div><div>Julian</div><div><br><div><div>Am 01.08.2017 um 11:52 schrieb Alexander Mentink:</div><br class="Apple-interchange-newline"><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; "><div dir="ltr"><div id="divtagdefaultwrapper" style="font-size: 12pt; color: rgb(0, 0, 0); background-color: rgb(255, 255, 255); font-family: Calibri, Arial, Helvetica, sans-serif; "><div style="margin-top: 0px; margin-bottom: 0px; ">Hi Fieldtrip community,</div><div style="margin-top: 0px; margin-bottom: 0px; "><br></div><div style="margin-top: 0px; margin-bottom: 0px; ">I am trying to analyse time frequency representations of electrical evoked potentials, but I am not getting any reliable results at all.</div><div style="margin-top: 0px; margin-bottom: 0px; "><br></div><div style="margin-top: 0px; margin-bottom: 0px; ">Using hanning window (1-30 Hz) or (4-30 Hz), wavelet transform with absolute baselinetype and relative baselinetype gives me four totally different results (see link)</div><div style="margin-top: 0px; margin-bottom: 0px; "><br></div><div style="margin-top: 0px; margin-bottom: 0px; "><a href="http://tinyurl.com/y7nerh8v" id="LPlnk953677">http://tinyurl.com/y7nerh8v</a><br><br></div><div style="margin-top: 0px; margin-bottom: 0px; ">The EEG data is defined 1000 ms pre stimulus and 1200 ms post stimulus, artifacts removed and preprocessed with baseline correction between 200 ms and 0 ms, bandpass filtered between 0.5 - 30 Hz and referenced to earlobes. The timelocked analysis is attached to the dropbox link as well.</div><div style="margin-top: 0px; margin-bottom: 0px; "><br></div><div style="margin-top: 0px; margin-bottom: 0px; "><b>The code I use for hanning window is</b></div><div style="margin-top: 0px; margin-bottom: 0px; ">%%%%%%%%%%%%%%%%%%</div><p style="margin-top: 0px; margin-bottom: 0px; "></p><div>cfg = [];<br>cfg.output = 'pow';<br>cfg.channel = 'Cz';<br>cfg.method = 'mtmconvol'; <br>cfg.taper = 'hanning'; <br>cfg.foi = 1:0.025:30; % OR 4:0.025:30<br>cfg.t_ftimwin = 3./cfg.foi; <br>cfg.toi = -0.5:0.01:0.7; <br>TFRwave = ft_freqanalysis(cfg, trialdata);<br><br></div><div>% Visualization<br>cfg = [];<br>cfg.baseline = [-0.5 -0.1]; <br>cfg.baselinetype = 'absolute'; <br>cfg.maskstyle = 'saturation';<br>cfg.zlim = [0 1];<br>cfg.showlabels = 'yes'; <br>figure<br>ft_singleplotTFR(cfg, TFRwave)</div><div><span style="font-family: Calibri, Arial, Helvetica, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', NotoColorEmoji, 'Segoe UI Symbol', 'Android Emoji', EmojiSymbols; font-size: 16px; ">%%%%%%%%%%%%%%%%%%</span><br></div><div><span style="font-family: Calibri, Arial, Helvetica, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', NotoColorEmoji, 'Segoe UI Symbol', 'Android Emoji', EmojiSymbols; font-size: 16px; "><br></span></div><div><b>And for wavelet transform is</b></div><div><span style="font-family: Calibri, Arial, Helvetica, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', NotoColorEmoji, 'Segoe UI Symbol', 'Android Emoji', EmojiSymbols; font-size: 16px; ">%%%%%%%%%%%%%%%%%%</span><br></div><div><div>cfg = [];</div><div>cfg.channel = 'Cz';<span style="white-space: pre; "> </span> </div><div>cfg.method = 'wavelet'; </div><div>cfg.width = 7; </div><div>cfg.output = 'pow';<span style="white-space: pre; "> </span></div><div>cfg.foi = 1:0.5:30;<span style="white-space: pre; "> </span> </div><div>cfg.toi = -0.5:0.05:1;<span style="white-space: pre; "> </span></div><div>TFRwave = ft_freqanalysis(cfg, trialdata);</div><div><br></div><div><span style="font-size: 12pt; ">cfg = [];</span><br></div><div>cfg.baseline = [-0.5 -0.1]; </div><div>cfg.baselinetype = 'relative'; % OR absolute</div><div>cfg.maskstyle = 'saturation';<span style="white-space: pre; "> </span></div><div>cfg.zlim = [0 1];<span style="white-space: pre; "> </span></div><div>cfg.channel = 'Cz';</div><div><span style="font-size: 12pt; ">figure</span><br></div><div>ft_singleplotTFR(cfg, TFRwave);</div><span style="font-family: Calibri, Arial, Helvetica, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', NotoColorEmoji, 'Segoe UI Symbol', 'Android Emoji', EmojiSymbols; font-size: 16px; ">%%%%%%%%%%%%%%%%%%</span><br></div><div><span style="font-family: Calibri, Arial, Helvetica, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', NotoColorEmoji, 'Segoe UI Symbol', 'Android Emoji', EmojiSymbols; font-size: 16px; "><br></span></div><div>I have tried the tutorials online, but this doesn't give me any better results...</div><div><br></div><div>Does anyone know what I am doing wrong?</div><div><br></div><div>Thanks many times!</div><div><br></div><div>Best regards,</div><div><br></div><div>Alex (Master student </div><br><p style="margin-top: 0px; margin-bottom: 0px; "></p></div><br><br><table class="ImprintUniqueIDTable" cellspacing="0" cellpadding="0" border="0" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm; height: 254px; width: 422px; border-collapse: collapse; "><tbody><tr><td style="width: 354px; "><font face="Verdana"><br></font><font style="font-family: Verdana; font-size: 12pt; font-weight: bold; ">Alexander Mentink</font> <br><font face="Verdana">Centre for Human Drug Research<br>Zernikedreef 8<br>2333 CL Leiden<br>The Netherlands</font><font style="font-family: Verdana; font-size: 12pt; "><br>T +31 (0) 71 7517166</font><br><font style="font-family: Verdana; font-size: 12pt; "><a href="mailto:amentink@chdr.nl">amentink@chdr.nl</a></font><br><font face="Verdana"><a href="http://www.chdr.nl">http://www.chdr.nl</a><br><br>Follow us:</font><table cellpadding="0" cellspacing="0" class="7567ec92-35cb-4269-b059-5b2b31db7757Table" style="font-family: Verdana; font-size: 12pt; text-align: left; vertical-align: top; "><tbody><tr style="text-align: left; vertical-align: top; "><td align="Center" style="padding-right: 5px; "><font style="font-family: Verdana; font-size: 12pt; "><font style="font-family: Verdana; font-size: 12pt; "><a href="http://www.twitter.com/chdr_nl" target=""><span><imaged4db2c.PNG></span></a></font></font></td><td align="Center" style="padding-right: 5px; "><font style="font-family: Verdana; font-size: 12pt; "><font style="font-family: Verdana; font-size: 12pt; "><a href="http://www.linkedin.com/company/centre-for-human-drug-research" target=""><span><imagecccaa4.PNG></span></a></font></font></td></tr></tbody></table><br><br></td></tr></tbody></table><br><font face="Verdana"></font>_______________________________________________<br>fieldtrip mailing list<br><a href="mailto:fieldtrip@donders.ru.nl">fieldtrip@donders.ru.nl</a><br><a href="https://mailman.science.ru.nl/mailman/listinfo/fieldtrip">https://mailman.science.ru.nl/mailman/listinfo/fieldtrip</a></div></span></blockquote></div><br></div></body></html>