How can I label my EEG-data plotting in gui?
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
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 commentaires
Réponses (1)
David J. Mack
le 12 Jan 2017
Modifié(e) : David J. Mack
le 12 Jan 2017
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 commentaires
Voir également
Catégories
En savoir plus sur Migrate GUIDE Apps dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!