Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

GUI & data plotting

Status
Not open for further replies.

barney75

Mechanical
Jan 22, 2007
58
IT
Hi guys,
I have to plot a serie of data (x,y) that are read from a text file. How can is it possible to store the data in a variable in the workspace in order to make it possible to access/process the data after each action (for example after pushing a button etc. etc.) without reading the txt file each time (it's a huge file and it requires some minutes to be read).

Thanks in advance

Bye
 
Replies continue below

Recommended for you

Hi,
got around it, using the assignin and evalin I solved the problem storing the data in the base workspace and extrancting later on when I need them.

Bye
 
If you are fiddling with GUIs in Matlab, there are ways of storing data local to the GUI. Each graphical element (including GUI ones) has a 'userdata' attribute that can be used to store almost anything.

- Steve
 
Also, read up on setappdata and getappdata. Very useful in GUI programming.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor