Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

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

How to plot within Guide determined area

Status
Not open for further replies.

ghakkens

Mechanical
Joined
May 1, 2003
Messages
1
Location
ES
I define within guide an area to plot a graphical function. The file.m program launches correctly, but the graphic is plotted in a separate window, instead of the destined area I define under guide.

As I use active buttons, it would be nicer to have the plot alongside the buttons.

Any help would be appreciated

Geoffrey

function varargout = pushbutton1_Callback(h, eventdata, handles, varargin)
% Stub for Callback of the uicontrol handles.pushbutton1.
disp('pushbutton1 Callback not implemented yet.')
axes(handles.axes1)
[X,Y,Z] = peaks(30);
handles.data = [X , Y , Z] ;
guidata(h, handles);

mesh(handles.data)
 
Before you plot, you need to make the GUI window the active figure using

figure(GUI_figure_handle);

M
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top