[Eeglablist] How to "difference plot" of coherences from two different datasets or conditions in SIFT and/or EEGLAB

Mikołaj Magnuski imponderabilion at gmail.com
Thu Feb 13 09:24:02 PST 2014


You can also plot the measures with imagesc if you
want to create a customized figure.
The Conn matrices are [to x from x freq x time]
(checked yesterday to be sure :) ) so to plot for
example first kept IC --> second kept IC one can:

% PLOT WITH IMAGESC
% change 'your_measure' to your measure of interest,
% use abs() or abs().^2 if your data are complex
imh = imagesc(squeeze(EEG.CAT.Conn.your_measure(2, 1, :, :)));

% adjust the color scale (imagesc does it by itself
% but sometimes you want to have the same scale on all figures)
caxis([0, 0.2]);
% plot freqs rising from bottom to top
set(gca, 'YDir', 'normal');

% set xdata and ydata so that you see time and
% frequency pixel coordinates:
wint = EEG.CAT.Conn.erWinCenterTimes; % event related times for window
centers
set(imh, 'XData', [wint(1), wint(end)]);
set(gca, 'XLim', [wint(1), wint(end)]);
freq = EEG.CAT.Conn.freqs;
set(imh, 'YData', [freq(1), freq(end)]);
set(gca, 'YLim', [freq(1), freq(end)]);
clear wint freq

% you can also set the tics, add labels, title, lines etc. but the above is
the basic setup
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://sccn.ucsd.edu/pipermail/eeglablist/attachments/20140213/88c518fc/attachment.html 


More information about the eeglablist mailing list