Lets say someone made a Matlab GUI using GUIDE. Now I want to use that code in a programmatic environment - that is no human-in-the-loop. What\'s the easiest way for me to \
MTALAB GUI is Java GUI. For the GUI automation there is a recent post on the blog of Yair Altman: http://undocumentedmatlab.com/blog/gui-automation-robot/
Following applies only if you can rewrite the application.
There is usually no need for any form of GUI automation for such tasks as yours. Application should have following architecture: Model->Business Logic->GUI. Each layer is decoupled from layers above it - Model knows nothing about Business Logic which knows nothing about the GUI. It is then possible to call Business Logic programmatically without even displaying the GUI. Here is an example for MVC implementation in MATLAB.
For this reason GUIDE should be avoided. There is an undocumented layout manager in MATLAB, there are also some on the file exchange.
In your case you could put the whole Business Logic outside the GUI Logic making GUIDE callbacks do nothing but call your Business Logic functions.
Extract form the following post. Use
guiname('pushbutton', object, eventdata, handles)
to call callbacks in 'guiname'.
Have you considered using a MVC pattern. Extracting the 'model' from your GUI might leave you with reusable code.