Re: Save
- From: "Gerald Dalley" <dalleyg@xxxxxxx>
- Date: Fri, 15 Sep 2006 07:54:50 -0400
Gerald Dalley wrote:
line?
Anthony wrote:
end
Hi..
I have this problem:
I make a subplot that contains a lot of information and at the
Iline
need to plot a line for each plot.
After that, the user can select to change the position of the
with some values taken from a listbox.subplot
For the momment, I have to plot everything again when the user
changes the position line... so It takes a lot of time..
my question is: is it possible to save all the info of one
and then just replot it when I need it, just adding the new
Thank you very much in advanced!
Anthony
It's not completely clear to me what you're asking, but I think the
following will help you...
When you create your plots, save the handles to them, e.g. the
first
time you plot a line, do something like:
h(mylinenum) = plot(x, y);
Then, when the user updates the x and y values,
set(h, 'XData',x, 'YData',y);
If it's in a loop or something like that, you might need a call to
drawnow as well.
Quick correction:
set(h(mylinenum), 'XData',x, 'YData',y);
where I'm assuming you're keeping track of multiple lines and
mylinenum is a variable indicating which plot line you want to
create/modify.
Consider reading the matlab doc section on handle graphics:
<http://www.mathworks.com/access/helpdesk/help/techdoc/creating_plots/f7-20419.html>
.
- Prev by Date: Re: De-checking Checkboxes
- Next by Date: Re: histeq gives different results depending on input type
- Previous by thread: Re: Save
- Next by thread: Problem having acces to libpointer value
- Index(es):
Relevant Pages
|