My First GUI: open a file, read the data, select which columns to plot, then plot it
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
This is my first GUI build using GUIDE, please bear with me, as I have watched about a dozen tutorial videos, but have yet to have my question answered.
I have created a GUI with an axes, a push button called "select file", a listbox with parameters of interest, and another push button that says "graph".
In the "select file" button, I have successfully coded it to read the file of interest, and aggregate all the data.
My issue is how do I update/populate the listbox with the headers from the data that I read? Then after the parameter(s) of interest is/are selected, how do I get the "graph" button to generate the graph?
I think what I'm missing is understanding of how I can pass the aggregate data to other functions (which essential are other UI components right?)
All help is highly appreciated. I'm going to continue looking through tutorial videos in the mean while.
0 comentarios
Respuestas (1)
John Petersen
el 18 de En. de 2013
Editada: John Petersen
el 18 de En. de 2013
To update a listbox with tag "mylistbox" with a cell of strings in mylistboxstr
set(handles.mylistbox, 'String', mylistboxstr);
To graph x,y data on an axes with tag "myaxes"
plot(handles.myaxes, x,y);
Use setappdata() and getappdata() to store and retrieve your data in different functions.
Ver también
Categorías
Más información sobre Migrate GUIDE Apps en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!