Introduction - If you have any usage issues, please Google them yourself
Generate Data to Plot
This topic shows you how to generate the data to be plotted when the GUI user clicks a button. The opening function generates this data by calling MATLAB functions. The opening function, which initializes a GUI when it opens, is the first callback in every GUIDE-generated GUI code file.
In this example, you add code that creates three data sets to the opening function. The code uses the MATLAB functions peaks, membrane, and sinc.