Azzera filtri
Azzera filtri

Creating an "update" button in GUI

3 visualizzazioni (ultimi 30 giorni)
Jared
Jared il 2 Nov 2011
I have a few check boxes and toggles which will affect the display of a plot I create with a GUI.
If I create a plot, then the user selects some of the check boxes to change the display, I think I need an update button to cause the data to be re-plotted using the new settings. Is there some command to, on the pressing of the "update button", jump back to the plot section of code?

Risposta accettata

Walter Roberson
Walter Roberson il 2 Nov 2011
No, there is not. In MATLAB, there is no way to jump back to anything.
What you should do is put the plotting code in to a function, and call that function from your regular code to do the initial plot. Then, in the callback for your Update button, call the plotting function.

Più risposte (0)

Categorie

Scopri di più su 2-D and 3-D Plots in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by