<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/159441</link>
    <title>MATLAB Central Newsreader - plots with for loops..URGENT PLZ</title>
    <description>Feed for thread: plots with for loops..URGENT PLZ</description>
    <language>en-us</language>
    <copyright>&amp;copy;1994-2012 by MathWorks, Inc.</copyright>
    <webmaster>webmaster@mathworks.com</webmaster>
    <generator>MATLAB Central Newsreader</generator>
    <docs>http://blogs.law.harvard.edu/tech/rss</docs>
    <ttl>60</ttl>
    <image>
      <title>MathWorks</title>
      <url>http://www.mathworks.com/images/membrane_icon.gif</url>
    </image>
    <item>
      <pubDate>Fri, 16 Nov 2007 15:07:27 -0500</pubDate>
      <title>plots with for loops..URGENT PLZ</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/159441#401695</link>
      <author>Abinayan Parthiban</author>
      <description>hi,&lt;br&gt;
Im starting to learn matlab,and I  have a problem.&lt;br&gt;
Basically, I have 2 column matrices, &lt;br&gt;
X=[1;2;3;4;5;6;7],Y=[1;3;5;6;8;7;9]..&lt;br&gt;
I want to plot them for each coordinates, but I want them &lt;br&gt;
to plot each coordinate in the graph after a 2 second &lt;br&gt;
interval. So, the plot looks something like this,&lt;br&gt;
&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|                                  |&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|          ---&amp;gt; after 2 seconds--&amp;gt; |     .(1,3)&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|  .(1,1)                          |&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;|_______                           |_______&lt;br&gt;
&lt;br&gt;
And so, on.. It should be on the same plot, so that it &lt;br&gt;
looks like an animation.&lt;br&gt;
I was trying to use the basic plot(x,y) with a for loop, &lt;br&gt;
and trying to find some kind of a delay function, so that &lt;br&gt;
it delays the plot by 2 secs. Can anyone please help me on &lt;br&gt;
this programme. Thanks.&lt;br&gt;
Abi.</description>
    </item>
    <item>
      <pubDate>Fri, 16 Nov 2007 15:15:21 -0500</pubDate>
      <title>Re: plots with for loops..URGENT PLZ</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/159441#401697</link>
      <author>Stuart Kozola</author>
      <description>Try:&lt;br&gt;
&lt;br&gt;
help pause&lt;br&gt;
&lt;br&gt;
'pause(2)' will pause for two seconds.  You should also look at 'drawnow' if &lt;br&gt;
your plot does not refresh as fast as you'd hoped.&lt;br&gt;
&lt;br&gt;
Stu&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&quot;Abinayan Parthiban&quot; &amp;lt;abinayanp@yahoo.co.uk&amp;gt; wrote in message &lt;br&gt;
news:fhkbnf$56v$1@fred.mathworks.com...&lt;br&gt;
&amp;gt; hi,&lt;br&gt;
&amp;gt; Im starting to learn matlab,and I  have a problem.&lt;br&gt;
&amp;gt; Basically, I have 2 column matrices,&lt;br&gt;
&amp;gt; X=[1;2;3;4;5;6;7],Y=[1;3;5;6;8;7;9]..&lt;br&gt;
&amp;gt; I want to plot them for each coordinates, but I want them&lt;br&gt;
&amp;gt; to plot each coordinate in the graph after a 2 second&lt;br&gt;
&amp;gt; interval. So, the plot looks something like this,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;      |                                  |&lt;br&gt;
&amp;gt;      |          ---&amp;gt; after 2 seconds--&amp;gt; |     .(1,3)&lt;br&gt;
&amp;gt;      |  .(1,1)                          |&lt;br&gt;
&amp;gt;      |_______                           |_______&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; And so, on.. It should be on the same plot, so that it&lt;br&gt;
&amp;gt; looks like an animation.&lt;br&gt;
&amp;gt; I was trying to use the basic plot(x,y) with a for loop,&lt;br&gt;
&amp;gt; and trying to find some kind of a delay function, so that&lt;br&gt;
&amp;gt; it delays the plot by 2 secs. Can anyone please help me on&lt;br&gt;
&amp;gt; this programme. Thanks.&lt;br&gt;
&amp;gt; Abi. </description>
    </item>
    <item>
      <pubDate>Fri, 16 Nov 2007 15:35:47 -0500</pubDate>
      <title>Re: plots with for loops..URGENT PLZ</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/159441#401704</link>
      <author>Abinayan Parthiban</author>
      <description>oh.. will look for it in the help.. thanks very much for &lt;br&gt;
that..&lt;br&gt;
Now if I wanted to plot each coordinates one at a time, how &lt;br&gt;
do i use the for loop for that? &lt;br&gt;
X=[1;2;3;4;5;6;7],Y=[1;3;5;6;8;7;9]&lt;br&gt;
&amp;nbsp;those are the coordinates.&lt;br&gt;
Thanks.&lt;br&gt;
&lt;br&gt;
Abi.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&quot;Stuart Kozola&quot; &amp;lt;skozola@mathworks.com&amp;gt; wrote in message &lt;br&gt;
&amp;lt;fhkc6a$brv$1@fred.mathworks.com&amp;gt;...&lt;br&gt;
&amp;gt; Try:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; help pause&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; 'pause(2)' will pause for two seconds.  You should also &lt;br&gt;
look at 'drawnow' if &lt;br&gt;
&amp;gt; your plot does not refresh as fast as you'd hoped.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Stu&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &quot;Abinayan Parthiban&quot; &amp;lt;abinayanp@yahoo.co.uk&amp;gt; wrote in &lt;br&gt;
message &lt;br&gt;
&amp;gt; news:fhkbnf$56v$1@fred.mathworks.com...&lt;br&gt;
&amp;gt; &amp;gt; hi,&lt;br&gt;
&amp;gt; &amp;gt; Im starting to learn matlab,and I  have a problem.&lt;br&gt;
&amp;gt; &amp;gt; Basically, I have 2 column matrices,&lt;br&gt;
&amp;gt; &amp;gt; X=[1;2;3;4;5;6;7],Y=[1;3;5;6;8;7;9]..&lt;br&gt;
&amp;gt; &amp;gt; I want to plot them for each coordinates, but I want &lt;br&gt;
them&lt;br&gt;
&amp;gt; &amp;gt; to plot each coordinate in the graph after a 2 second&lt;br&gt;
&amp;gt; &amp;gt; interval. So, the plot looks something like this,&lt;br&gt;
&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt;      |                                  |&lt;br&gt;
&amp;gt; &amp;gt;      |          ---&amp;gt; after 2 seconds--&amp;gt; |     .(1,3)&lt;br&gt;
&amp;gt; &amp;gt;      |  .(1,1)                          |&lt;br&gt;
&amp;gt; &amp;gt;      |_______                           |_______&lt;br&gt;
&amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; And so, on.. It should be on the same plot, so that it&lt;br&gt;
&amp;gt; &amp;gt; looks like an animation.&lt;br&gt;
&amp;gt; &amp;gt; I was trying to use the basic plot(x,y) with a for loop,&lt;br&gt;
&amp;gt; &amp;gt; and trying to find some kind of a delay function, so &lt;br&gt;
that&lt;br&gt;
&amp;gt; &amp;gt; it delays the plot by 2 secs. Can anyone please help me &lt;br&gt;
on&lt;br&gt;
&amp;gt; &amp;gt; this programme. Thanks.&lt;br&gt;
&amp;gt; &amp;gt; Abi. &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; </description>
    </item>
    <item>
      <pubDate>Fri, 16 Nov 2007 15:37:33 -0500</pubDate>
      <title>Re: plots with for loops..URGENT PLZ</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/159441#401705</link>
      <author>Peter Boettcher</author>
      <description>&quot;Abinayan Parthiban&quot; &amp;lt;abinayanp@yahoo.co.uk&amp;gt; writes:&lt;br&gt;
&lt;br&gt;
&amp;gt; oh.. will look for it in the help.. thanks very much for &lt;br&gt;
&amp;gt; that..&lt;br&gt;
&amp;gt; Now if I wanted to plot each coordinates one at a time, how &lt;br&gt;
&amp;gt; do i use the for loop for that? &lt;br&gt;
&amp;gt; X=[1;2;3;4;5;6;7],Y=[1;3;5;6;8;7;9]&lt;br&gt;
&amp;gt;  those are the coordinates.&lt;br&gt;
&amp;gt; Thanks.&lt;br&gt;
&lt;br&gt;
How do you plot just the first point?  How do you plot just the second&lt;br&gt;
point?  Do those at the command line.&lt;br&gt;
&lt;br&gt;
Then, how do you generalize that to plot the i'th point.  Try it out.&lt;br&gt;
&lt;br&gt;
Then, wrap that line in a loop that sets i to changing values.&lt;br&gt;
&lt;br&gt;
-Peter</description>
    </item>
  </channel>
</rss>

