How can I label my EEG-data plotting in gui?
3 ビュー (過去 30 日間)
古いコメントを表示
Hey,
atm I am working on some EEG-data. I am about to make a window where the user can plot several neurodata (about 60 channels) and zoom in to take a closer look at a channel and erase it. To be able to erase it the user has to click and the popup menu which channel he wants to delete. How can I label all 60 channels so one can read the label all over the (e.g.) 1500ms and zoom in in gui?
Thanks for any helpful answer
Jenny
0 件のコメント
回答 (1 件)
David J. Mack
2017 年 1 月 12 日
編集済み: David J. Mack
2017 年 1 月 12 日
Is your data all in the same axes or in separate subplot s? In the first case use the text function and set its 'Unit' property to 'normalized' which will show the label in the same place regardless of zoom (e.g. w.r.t. the axes instead of the data). Here is a short example:
figure;
plot(rand(100,1));
text(50,0.5,'text in data space')
set(text(50,0.6,'text in axes space'),'Units','normalized') %Place the text in the same location & then switch units)
If you use the zoom tool you will see the difference.
Assuming you want to label n<100 channels according to "chXX" and their y-locations are given in vector y, then:
labels = strcat({'ch'},num2str((1:n)','%02d'));
x = repmat(min(xlim(gca)),size(y));
set(text(x,y,labels,'Units','normalized');
puts the labels at the left border of the current axes.
Greetings, David
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Migrate GUIDE Apps についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!