Effacer les filtres
Effacer les filtres

How to display a value number in the figure

11 vues (au cours des 30 derniers jours)
Claire Redfield
Claire Redfield le 19 Fév 2013
Hello guys, I have made a GUI. I would like to link a function to one of the buttons so that when clicking on it a picture will show the result(a variable x ).
Could you tell me how to do this thing similar to imshow(x), but x is a 1 by 1 number pls?

Réponse acceptée

Titus Edelhofer
Titus Edelhofer le 19 Fév 2013
Hi,
you can use a text uicontrol. So in GUIDE you add a text, and in the callback of your button you have something like
x = 42;
set(handles.text1, 'string', ['Result: ' num2str(x)]);
Titus

Plus de réponses (0)

Catégories

En savoir plus sur Migrate GUIDE Apps dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by