Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Creating a GUI consists of two steps. Step 1 is to design the user interface including figures, buttons and
menus. Step 2 is to create the Matlab code that runs when buttons are pressed. The code goes in callback
functions that are activated each time a button is pressed. For an example of a GUI application, see
>>graf2d
>>edit graf2d
To make things simple, Matlab includes a GUIDE application that provides a WYSIWYG interface for
laying out components on the screen and creates stub callback functions. GUIDE is ideal for most simple
GUI applications. Start GUIDE from the Matlab command line
>>guide
then use the online help for GUIDE to get started. Also see Matlab 7 manual, "Creating Graphical User
Interfaces" (PDF file, 480 pages), available on-line at the Mathworks web site. To see more samples, when
GUIDE starts, select the GUI with Uicontrols template and look at the generated code.
The following instructions are for Matlab 7. Other versions are similar.