GUI: How do I hide the plotted data associated with a specific 'hidden' axis
156 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I made a gui that shows 2 plots out of 58 at a time on a panel. These plots are all generated at the same time with their respective axes. The 56 axes that are not being viewed, are at some 'position' outside of the panels scope.
-slightly laggy I know! When I switch from first pair of axes to the next, all 58 plots axes switch positions slightly. I have their positions coded like a converyor belt if you will. First look at the first set, then the following and so on, moving all of the plot positions when viewing the next pair of axes.
So I decided to turn off the visibility of 75% of the panels while I am viewing the first 25% and then turn off the first 25% while I am vieiwing 26-50% and so on. GUI works MUCH faster but now I am having a slight issue with what is visible and what isn't.
Issue: The plotted data is still showing up while the axes itself is hidden! how do i overcome this??
here are a few pictures.
Ideally: the plot and data would completely turn off or be invisible while I am not viewing them.
0 commentaires
Réponse acceptée
Adam Danz
le 5 Août 2019
Modifié(e) : Adam Danz
le 6 Août 2019
"How do I hide the plotted data associated with a specific 'hidden' axis? "
Turn visibility off on the axes and all of its children. Here's a demo that creates 2 subplots, plots some stuff, and then turns off the 2nd subplot and all of its children.
figure()
sph(1) = subplot(2,1,1);
plot(rand(1,80), 'o')
sph(2) = subplot(2,1,2);
plot(rand(1,80), 'o')
hold on
lsline()
% Turn off axis and all data on the axis
set([sph(2);sph(2).Children], 'Visible','off') %<--vertically concatenate all handles.
2 commentaires
Adam Danz
le 6 Août 2019
The last line in my answer does that. To adapt it to your variables,
set([PlotAX17;PlotAX17.Children], 'Visible','off')
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Visual Exploration 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!