MATLAB SIMULINK 7 - GRAPHICAL USER INTERFACE Guida Utente Pagina 314

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 759
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 313
8 Programming a GUIDE GUI
1 Add this code to the Plot 1 push button’s Callback callback. The surf
function produces a 3-D shaded surface plot. The peaks function returns a
square matrix obtained by translating and scaling Gaussian distributions.
surf(handles.axes1,peaks(35));
2 Add this code to the Plot 2 push button’s Callback callback. The contour
function displays the contour plot of a matrix, in this case the output
of
peaks.
contour(handles.axes2,peaks(35));
3 Run the GUI by selecting Run fro m the Tools menu.
4 Click the Plot 1 button to display the surf plot in the first axes. Click the
Plot 2 button to display the contour plot in the second axes.
See “GUI with Multiple Axes (GUIDE)” on page 10-2 for a more complex
example that uses two axes.
8-46
Vedere la pagina 313
1 2 ... 309 310 311 312 313 314 315 316 317 318 319 ... 758 759

Commenti su questo manuale

Nessun commento