Back to the main page.

Bug 2627 - Possible bug with 'outline' option in ft_singleplotTFR

Status CLOSED WORKSFORME
Reported 2014-06-30 09:08:00 +0200
Modified 2019-08-10 12:28:22 +0200
Product: FieldTrip
Component: plotting
Version: unspecified
Hardware: PC
Operating System: Windows
Importance: P5 normal
Assigned to: Eelke Spaak
URL:
Tags:
Depends on:
Blocks:
See also:

Eelke Spaak - 2014-06-30 09:08:20 +0200

Post on mailing list: Jim Parkinson <jimparkinson@me.com> 26 Jun (4 days ago) to fieldtrip Hi I have been using ft_singleplotTFR along with the 'outline' option to mask areas of the plot as given by an ft_freqstatistics output. I started to notice that the outline didn't match up with what (by eyeball!) should be outlined. So I checked the function by using ft_singleplotTFR cfg = []; cfg.parameter = 'mask'; cfg.channel = 'Cz'; cfg.zlim = [0 1]; % masks cfg.maskparameter = 'mask'; cfg.maskstyle = 'outline'; cfg.renderer = 'opengl'; ft_singleplotTFR(cfg,td); therefore I am plotting the mask data (zeros or ones) and also using that data as the outline parameter - so the outline should be EXACTLY around the RED area (ones), right? This doesn't happen (screencap here: https://www.dropbox.com/s/3lnu4f63wq0zdg2/OutlineDemo.png). However, the 'opacity' and 'saturation' methods work fine, and perfectly bounds the mask area. Has anyone else had this issue with 'outline', have any pointers, or alternatives that are easy to implement. p.s., I've replicated this with all rendering options, on both Mac and Linux Thanks for any help Jim


Eelke Spaak - 2014-08-06 12:23:44 +0200

Just e-mailed Jim Parkinson: Hi Jim, Sorry for the slow reply. I tried to reproduce your report, but I am getting perfectly normal results with the following code: %% create some data freq = []; freq.label = {'a'}; freq.freq = 1:40; freq.time = 0.05:0.05:3; freq.dimord = 'chan_freq_time'; freq.powspctrm = randn(1, numel(freq.freq), numel(freq.time)); freq.mask = zeros(size(freq.powspctrm)); freq.mask(1,15:25,20:30) = 1; %% plot cfg = []; cfg.channel = 'a'; cfg.maskparameter = 'mask'; cfg.parameter = 'mask'; cfg.maskstyle = 'outline'; cfg.renderer = 'opengl'; ft_singleplotTFR(cfg, freq); see attached. Could you update to the latest FT version and tell me whether the problem still persists? Thanks. (By the way, it would be better to continue this discussion at our bugzilla: http://bugzilla.fcdonders.nl/show_bug.cgi?id=2627 You can create an account there with just your e-mail address and add comments to the bug.) Best, Eelke


Eelke Spaak - 2014-11-26 12:05:24 +0100

No reply from Jim Parkinson anymore, so marking as worksforme.


Robert Oostenveld - 2019-08-10 12:28:22 +0200

This closes a whole series of bugs that have been resolved (either FIXED/WONTFIX/INVALID) for quite some time. If you disagree, please file a new issue describing the issue on https://github.com/fieldtrip/fieldtrip/issues.