<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736</link>
    <title>MATLAB Central Newsreader - extract dynamically the headerlines row numvber by string/number txt </title>
    <description>Feed for thread: extract dynamically the headerlines row numvber by string/number txt </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>Sun, 29 Jun 2008 18:27:56 -0400</pubDate>
      <title>extract dynamically the headerlines row numvber by string/number txt </title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440132</link>
      <author>Engeltje</author>
      <description>hi, everybody...I had a problem.&lt;br&gt;
I work with some namefile.tsv (a kind of txt files) that arecomposed&lt;br&gt;
by some headerlines, containg string values and number values in Date&lt;br&gt;
format and in the end of the file it contains some numerical colomns.&lt;br&gt;
I want&lt;br&gt;
either the row number of the begin of these numerical data, descarting&lt;br&gt;
the headerlines, end the row number of the end of the file&lt;br&gt;
or just the numbers contained in the end of the file disposed as a&lt;br&gt;
table.&lt;br&gt;
&lt;br&gt;
How can I obtain that dynamically? tha is create a function that do&lt;br&gt;
this work for different file with different numbers of headerlines?&lt;br&gt;
&lt;br&gt;
please help me!!!&lt;br&gt;
&lt;br&gt;
thx, angelo!</description>
    </item>
    <item>
      <pubDate>Sun, 29 Jun 2008 19:15:49 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number </title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440134</link>
      <author>Rune Allnor</author>
      <description>On 29 Jun, 20:27, Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; I work with some namefile.tsv (a kind of txt files) that arecomposed&lt;br&gt;
&amp;gt; by some headerlines, containg string values and number values in Date&lt;br&gt;
&amp;gt; format and in the end of the file it contains some numerical colomns.&lt;br&gt;
&amp;gt; I want&lt;br&gt;
&amp;gt; either the row number of the begin of these numerical data, descarting&lt;br&gt;
&amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; or just the numbers contained in the end of the file disposed as a&lt;br&gt;
&amp;gt; table.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; How can I obtain that dynamically? tha is create a function that do&lt;br&gt;
&amp;gt; this work for different file with different numbers of headerlines?&lt;br&gt;
&lt;br&gt;
If you know the format of the table you are looking for,&lt;br&gt;
you can use a regular expression to search for it, and&lt;br&gt;
discard the lines that don't match the pattern.&lt;br&gt;
&lt;br&gt;
Rune</description>
    </item>
    <item>
      <pubDate>Mon, 30 Jun 2008 08:44:09 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number </title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440212</link>
      <author>Engeltje</author>
      <description>On 29 Giu, 21:15, Rune Allnor &amp;lt;all...@tele.ntnu.no&amp;gt; wrote:&lt;br&gt;
&amp;gt; On 29 Jun, 20:27, Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; &amp;gt; I work with some namefile.tsv (a kind of txt files) that arecomposed&lt;br&gt;
&amp;gt; &amp;gt; by some headerlines, containg string values and number values in Date&lt;br&gt;
&amp;gt; &amp;gt; format and in the end of the file it contains some numerical colomns.&lt;br&gt;
&amp;gt; &amp;gt; I want&lt;br&gt;
&amp;gt; &amp;gt; either the row number of the begin of these numerical data, descarting&lt;br&gt;
&amp;gt; &amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; &amp;gt; or just the numbers contained in the end of the file disposed as a&lt;br&gt;
&amp;gt; &amp;gt; table.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; How can I obtain that dynamically? tha is create a function that do&lt;br&gt;
&amp;gt; &amp;gt; this work for different file with different numbers of headerlines?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; If you know the format of the table you are looking for,&lt;br&gt;
&amp;gt; you can use a regular expression to search for it, and&lt;br&gt;
&amp;gt; discard the lines that don't match the pattern.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Rune&lt;br&gt;
&lt;br&gt;
Actually, if you mean with &quot;format&quot;, what kind of type the colomns&lt;br&gt;
are, they're integer and float!&lt;br&gt;
But if you mean if they're of the same colomns number, the answer is&lt;br&gt;
no! these files are different!!&lt;br&gt;
But we have in the bottom of these files some colomns of number, and I&lt;br&gt;
don't know if matlab can see those as a table.&lt;br&gt;
I'm very confused!&lt;br&gt;
and If I can search for it, How can I do that discarding the&lt;br&gt;
headerlines?&lt;br&gt;
For instance in the first colomn the discarding lines are string&lt;br&gt;
values, while the interesting ones are integer value!&lt;br&gt;
Can u let me see an example? if u can...&lt;br&gt;
thx to answer!&lt;br&gt;
angelo</description>
    </item>
    <item>
      <pubDate>Mon, 30 Jun 2008 08:55:03 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number txt</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440214</link>
      <author>Miroslav Balda</author>
      <description>Engeltje &amp;lt;Engeltje81@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;lt;2924bec5-2274-4b3b-8354-20b34f59add2@m3g2000hsc.googlegroups.com&amp;gt;...&lt;br&gt;
&amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; I work with some namefile.tsv (a kind of txt files) that&lt;br&gt;
arecomposed&lt;br&gt;
&amp;gt; by some headerlines, containg string values and number&lt;br&gt;
values in Date&lt;br&gt;
&amp;gt; format and in the end of the file it contains some&lt;br&gt;
numerical colomns.&lt;br&gt;
&amp;gt; I want&lt;br&gt;
&amp;gt; either the row number of the begin of these numerical&lt;br&gt;
data, descarting&lt;br&gt;
&amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; or just the numbers contained in the end of the file&lt;br&gt;
disposed as a&lt;br&gt;
&amp;gt; table.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; How can I obtain that dynamically? tha is create a&lt;br&gt;
function that do&lt;br&gt;
&amp;gt; this work for different file with different numbers of&lt;br&gt;
headerlines?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; please help me!!!&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; thx, angelo!&lt;br&gt;
&lt;br&gt;
Hi Angelo,&lt;br&gt;
&lt;br&gt;
If the form of a file is not known in forward, you may use&lt;br&gt;
the function ffread (free format read) from FEX (Id 9034),&lt;br&gt;
which was developed just for the purpose.&lt;br&gt;
&lt;br&gt;
Good luck.&lt;br&gt;
&lt;br&gt;
Mira</description>
    </item>
    <item>
      <pubDate>Mon, 30 Jun 2008 09:01:13 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number </title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440215</link>
      <author>Rune Allnor</author>
      <description>On 30 Jun, 10:44, Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt; On 29 Giu, 21:15, Rune Allnor &amp;lt;all...@tele.ntnu.no&amp;gt; wrote:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; On 29 Jun, 20:27, Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; I work with some namefile.tsv (a kind of txt files) that arecomposed&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; by some headerlines, containg string values and number values in Date&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; format and in the end of the file it contains some numerical colomns.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; I want&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; either the row number of the begin of these numerical data, descarting&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; or just the numbers contained in the end of the file disposed as a&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; table.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; How can I obtain that dynamically? tha is create a function that do&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; this work for different file with different numbers of headerlines?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; If you know the format of the table you are looking for,&lt;br&gt;
&amp;gt; &amp;gt; you can use a regular expression to search for it, and&lt;br&gt;
&amp;gt; &amp;gt; discard the lines that don't match the pattern.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; Rune&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Actually, if you mean with &quot;format&quot;, what kind of type the colomns&lt;br&gt;
&amp;gt; are, they're integer and float!&lt;br&gt;
&amp;gt; But if you mean if they're of the same colomns number, the answer is&lt;br&gt;
&amp;gt; no! these files are different!!&lt;br&gt;
&lt;br&gt;
If you don't know what you are looking for and where to&lt;br&gt;
find it, you are in serious trouble.&lt;br&gt;
&lt;br&gt;
&amp;gt; But we have in the bottom of these files some colomns of number, and I&lt;br&gt;
&amp;gt; don't know if matlab can see those as a table.&lt;br&gt;
&lt;br&gt;
Matlab can't. You need to specify some properties that&lt;br&gt;
separate those lines from the uninteresting stuff.&lt;br&gt;
If you can do that, you can search for those prpoerties&lt;br&gt;
using regular expressions.&lt;br&gt;
&lt;br&gt;
&amp;gt; I'm very confused!&lt;br&gt;
&amp;gt; and If I can search for it, How can I do that discarding the&lt;br&gt;
&amp;gt; headerlines?&lt;br&gt;
&lt;br&gt;
Use regular expressions.&lt;br&gt;
&lt;br&gt;
&amp;gt; For instance in the first colomn the discarding lines are string&lt;br&gt;
&amp;gt; values, while the interesting ones are integer value!&lt;br&gt;
&lt;br&gt;
Use regular expressions.&lt;br&gt;
&lt;br&gt;
Rune</description>
    </item>
    <item>
      <pubDate>Mon, 30 Jun 2008 16:33:02 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number txt</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440288</link>
      <author>Miroslav Balda</author>
      <description>Engeltje &amp;lt;Engeltje81@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;lt;2924bec5-2274-4b3b-8354-20b34f59add2@m3g2000hsc.googlegroups.com&amp;gt;...&lt;br&gt;
&amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; I work with some namefile.tsv (a kind of txt files) that&lt;br&gt;
arecomposed&lt;br&gt;
&amp;gt; by some headerlines, containg string values and number&lt;br&gt;
values in Date&lt;br&gt;
&amp;gt; format and in the end of the file it contains some&lt;br&gt;
numerical colomns.&lt;br&gt;
&amp;gt; I want&lt;br&gt;
&amp;gt; either the row number of the begin of these numerical&lt;br&gt;
data, descarting&lt;br&gt;
&amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; or just the numbers contained in the end of the file&lt;br&gt;
disposed as a&lt;br&gt;
&amp;gt; table.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; How can I obtain that dynamically? tha is create a&lt;br&gt;
function that do&lt;br&gt;
&amp;gt; this work for different file with different numbers of&lt;br&gt;
headerlines?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; please help me!!!&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; thx, angelo!&lt;br&gt;
&lt;br&gt;
Hi,&lt;br&gt;
&lt;br&gt;
Could you send a small example file with some notes what&lt;br&gt;
data you like to read.? I'll try to read it&lt;br&gt;
&lt;br&gt;
Mira</description>
    </item>
    <item>
      <pubDate>Tue, 01 Jul 2008 08:40:15 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number </title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440452</link>
      <author>Engeltje</author>
      <description>On 30 Giu, 18:33, &quot;Miroslav Balda&quot; &amp;lt;balda.nos...@cdm.it.cas.cz&amp;gt; wrote:&lt;br&gt;
&amp;gt; Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;2924bec5-2274-4b3b-8354-20b34f59a...@m3g2000hsc.googlegroups.com&amp;gt;...&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; hi, everybody...I had a problem.&lt;br&gt;
&amp;gt; &amp;gt; I work with some namefile.tsv (a kind of txt files) that&lt;br&gt;
&amp;gt; arecomposed&lt;br&gt;
&amp;gt; &amp;gt; by some headerlines, containg string values and number&lt;br&gt;
&amp;gt; values in Date&lt;br&gt;
&amp;gt; &amp;gt; format and in the end of the file it contains some&lt;br&gt;
&amp;gt; numerical colomns.&lt;br&gt;
&amp;gt; &amp;gt; I want&lt;br&gt;
&amp;gt; &amp;gt; either the row number of the begin of these numerical&lt;br&gt;
&amp;gt; data, descarting&lt;br&gt;
&amp;gt; &amp;gt; the headerlines, end the row number of the end of the file&lt;br&gt;
&amp;gt; &amp;gt; or just the numbers contained in the end of the file&lt;br&gt;
&amp;gt; disposed as a&lt;br&gt;
&amp;gt; &amp;gt; table.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; How can I obtain that dynamically? tha is create a&lt;br&gt;
&amp;gt; function that do&lt;br&gt;
&amp;gt; &amp;gt; this work for different file with different numbers of&lt;br&gt;
&amp;gt; headerlines?&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; please help me!!!&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; thx, angelo!&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Could you send a small example file with some notes what&lt;br&gt;
&amp;gt; data you like to read.? I'll try to read it&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Mira&lt;br&gt;
&lt;br&gt;
Hi Mira!!!&lt;br&gt;
The problem I had I found a solution using the function&lt;br&gt;
txt2mat(filename,0,1) I take the first colomn and then I made a&lt;br&gt;
function that check if the result vector isnan (in this case increase&lt;br&gt;
first index) else increase second index.&lt;br&gt;
so thx to be interested!&lt;br&gt;
Now I actually have a new problem!&lt;br&gt;
I have some data in which part of the colomn is emtpy.&lt;br&gt;
Example:&lt;br&gt;
&lt;br&gt;
timestamp X Y value&lt;br&gt;
10&lt;br&gt;
20 3.2 3.4 4&lt;br&gt;
30&lt;br&gt;
40 1.2 2.7 10&lt;br&gt;
&lt;br&gt;
I use:&lt;br&gt;
values=textscan(filename,'%d %f %f %d', 4,'headerlines',1);&lt;br&gt;
&lt;br&gt;
[TS,GazePointX,GazePointY,val]=values{:}&lt;br&gt;
&lt;br&gt;
the problem is that it stops at TS=10, and the others are empty&lt;br&gt;
Can u help me?&lt;br&gt;
angelo</description>
    </item>
    <item>
      <pubDate>Tue, 01 Jul 2008 09:35:08 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440470</link>
      <author>Miroslav Balda</author>
      <description>Engeltje &amp;lt;Engeltje81@gmail.com&amp;gt; wrote in message&lt;br&gt;
&amp;lt;155421db-2dae-4c05-a69a-7bd91a8f6793@r66g2000hsg.googlegroups.com&amp;gt;...&lt;br&gt;
:&lt;br&gt;
SNIP&lt;br&gt;
:&lt;br&gt;
&amp;gt; Now I actually have a new problem!&lt;br&gt;
&amp;gt; I have some data in which part of the colomn is emtpy.&lt;br&gt;
&amp;gt; Example:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; timestamp X Y value&lt;br&gt;
&amp;gt; 10&lt;br&gt;
&amp;gt; 20 3.2 3.4 4&lt;br&gt;
&amp;gt; 30&lt;br&gt;
&amp;gt; 40 1.2 2.7 10&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I use:&lt;br&gt;
&amp;gt; values=textscan(filename,'%d %f %f %d', 4,'headerlines',1);&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; [TS,GazePointX,GazePointY,val]=values{:}&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; the problem is that it stops at TS=10, and the others are&lt;br&gt;
empty&lt;br&gt;
&amp;gt; Can u help me?&lt;br&gt;
&amp;gt; angelo&lt;br&gt;
&lt;br&gt;
Hi Angelo,&lt;br&gt;
&lt;br&gt;
I think that you have to use another approach to it, and&lt;br&gt;
read the file line by line. Look at &lt;br&gt;
help fgetl and&lt;br&gt;
help fgets.&lt;br&gt;
after getting a line contents you may analyze it by function&lt;br&gt;
sscanf &lt;br&gt;
and decide what to do with half-empty line.&lt;br&gt;
&lt;br&gt;
Mira</description>
    </item>
    <item>
      <pubDate>Tue, 01 Jul 2008 10:43:41 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440482</link>
      <author>Engeltje</author>
      <description>thx mira for ur advances!!&lt;br&gt;
but I'm really confused....the problem is that  I need 3 colomn&lt;br&gt;
vectors....so I try to use readline function and fgetl one...&lt;br&gt;
but I can't!!!&lt;br&gt;
the problem is that matlab see empty positions as to disgard them, but&lt;br&gt;
I need that it can see it so that if I want only first, 20th and 21th&lt;br&gt;
colomn values I can get them.&lt;br&gt;
&lt;br&gt;
If u can...can u show me how u'd make it with the example I write u in&lt;br&gt;
the past post?&lt;br&gt;
&lt;br&gt;
Thx a priori&lt;br&gt;
Angelo</description>
    </item>
    <item>
      <pubDate>Tue, 01 Jul 2008 15:20:19 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440547</link>
      <author>Andres </author>
      <description>Engeltje &amp;lt;Engeltje81@gmail.com&amp;gt; wrote in message &amp;lt;155421db-&lt;br&gt;
2dae-4c05-a69a-7bd91a8f6793@r66g2000hsg.googlegroups.com&amp;gt;...&lt;br&gt;
[..]&lt;br&gt;
&amp;gt; The problem I had I found a solution using the function&lt;br&gt;
&amp;gt; txt2mat(filename,0,1) I take the first colomn and then I &lt;br&gt;
made a&lt;br&gt;
&amp;gt; function that check if the result vector isnan (in this &lt;br&gt;
case increase&lt;br&gt;
&amp;gt; first index) else increase second index.&lt;br&gt;
&amp;gt; so thx to be interested!&lt;br&gt;
&amp;gt; Now I actually have a new problem!&lt;br&gt;
&amp;gt; I have some data in which part of the colomn is emtpy.&lt;br&gt;
&amp;gt; Example:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; timestamp X Y value&lt;br&gt;
&amp;gt; 10&lt;br&gt;
&amp;gt; 20 3.2 3.4 4&lt;br&gt;
&amp;gt; 30&lt;br&gt;
&amp;gt; 40 1.2 2.7 10&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; I use:&lt;br&gt;
&amp;gt; values=textscan(filename,'%d %f %f %d', &lt;br&gt;
4,'headerlines',1);&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; [TS,GazePointX,GazePointY,val]=values{:}&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; the problem is that it stops at TS=10, and the others are &lt;br&gt;
empty&lt;br&gt;
&amp;gt; Can u help me?&lt;br&gt;
&amp;gt; angelo&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Hi Angelo,&lt;br&gt;
&lt;br&gt;
did you try to use txt2mat with the filename as the only &lt;br&gt;
argument, i.e.&lt;br&gt;
&lt;br&gt;
A = txt2mat(filename)&lt;br&gt;
&lt;br&gt;
that would give &lt;br&gt;
&lt;br&gt;
A =&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;10.0000       NaN       NaN       NaN&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;20.0000    3.2000    3.4000    4.0000&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;30.0000       NaN       NaN       NaN&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;40.0000    1.2000    2.7000   10.0000&lt;br&gt;
&lt;br&gt;
for your example ? txt2mat has built in an automatic header &lt;br&gt;
line and column number detection. If you know the number of &lt;br&gt;
header lines in advance, you can also write&lt;br&gt;
&lt;br&gt;
A = txt2mat(filename,1)  % or&lt;br&gt;
A = txt2mat(filename,'NumHeaderLines',1)&lt;br&gt;
&lt;br&gt;
for a single header line, to be sure.&lt;br&gt;
&lt;br&gt;
Hth, regards&lt;br&gt;
Andres</description>
    </item>
    <item>
      <pubDate>Wed, 02 Jul 2008 10:43:05 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440726</link>
      <author>Engeltje</author>
      <description>On 1 Lug, 17:20, &quot;Andres &quot; &amp;lt;rant...@werb.de&amp;gt; wrote:&lt;br&gt;
&amp;gt; Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote in message &amp;lt;155421db-&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 2dae-4c05-a69a-7bd91a8f6...@r66g2000hsg.googlegroups.com&amp;gt;...&lt;br&gt;
&amp;gt; [..]&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; The problem I had I found a solution using the function&lt;br&gt;
&amp;gt; &amp;gt; txt2mat(filename,0,1) I take the first colomn and then I&lt;br&gt;
&amp;gt; made a&lt;br&gt;
&amp;gt; &amp;gt; function that check if the result vector isnan (in this&lt;br&gt;
&amp;gt; case increase&lt;br&gt;
&amp;gt; &amp;gt; first index) else increase second index.&lt;br&gt;
&amp;gt; &amp;gt; so thx to be interested!&lt;br&gt;
&amp;gt; &amp;gt; Now I actually have a new problem!&lt;br&gt;
&amp;gt; &amp;gt; I have some data in which part of the colomn is emtpy.&lt;br&gt;
&amp;gt; &amp;gt; Example:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; timestamp X Y value&lt;br&gt;
&amp;gt; &amp;gt; 10&lt;br&gt;
&amp;gt; &amp;gt; 20 3.2 3.4 4&lt;br&gt;
&amp;gt; &amp;gt; 30&lt;br&gt;
&amp;gt; &amp;gt; 40 1.2 2.7 10&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; I use:&lt;br&gt;
&amp;gt; &amp;gt; values=textscan(filename,'%d %f %f %d',&lt;br&gt;
&amp;gt; 4,'headerlines',1);&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; [TS,GazePointX,GazePointY,val]=values{:}&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; the problem is that it stops at TS=10, and the others are&lt;br&gt;
&amp;gt; empty&lt;br&gt;
&amp;gt; &amp;gt; Can u help me?&lt;br&gt;
&amp;gt; &amp;gt; angelo&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Hi Angelo,&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; did you try to use txt2mat with the filename as the only&lt;br&gt;
&amp;gt; argument, i.e.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; A = txt2mat(filename)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; that would give&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; A =&lt;br&gt;
&amp;gt;    10.0000       NaN       NaN       NaN&lt;br&gt;
&amp;gt;    20.0000    3.2000    3.4000    4.0000&lt;br&gt;
&amp;gt;    30.0000       NaN       NaN       NaN&lt;br&gt;
&amp;gt;    40.0000    1.2000    2.7000   10.0000&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; for your example ? txt2mat has built in an automatic header&lt;br&gt;
&amp;gt; line and column number detection. If you know the number of&lt;br&gt;
&amp;gt; header lines in advance, you can also write&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; A = txt2mat(filename,1)  % or&lt;br&gt;
&amp;gt; A = txt2mat(filename,'NumHeaderLines',1)&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; for a single header line, to be sure.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Hth, regards&lt;br&gt;
&amp;gt; Andres&lt;br&gt;
&lt;br&gt;
Hi Andres!! unfortunally I've just tried it!&lt;br&gt;
the problem is that my file is more complex then the one u've seen!!&lt;br&gt;
if u want to have an idea...if u give me ur emali address I will send&lt;br&gt;
it!&lt;br&gt;
let me know!!&lt;br&gt;
regards angelo</description>
    </item>
    <item>
      <pubDate>Wed, 02 Jul 2008 13:23:02 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#440744</link>
      <author>Andres </author>
      <description>Engeltje &amp;lt;Engeltje81@gmail.com&amp;gt; wrote in message &amp;lt;cb6bb0d2-&lt;br&gt;
fbf2-4fbf-9ec2-d636a39e3d81@p25g2000hsf.googlegroups.com&amp;gt;...&lt;br&gt;
[..]&lt;br&gt;
&amp;gt; if u want to have an idea...if u give me ur emali address &lt;br&gt;
I will send&lt;br&gt;
&amp;gt; it!&lt;br&gt;
&amp;gt; let me know!!&lt;br&gt;
&amp;gt; regards angelo&lt;br&gt;
&lt;br&gt;
Hi,&lt;br&gt;
i have just sent you an email. If that does not work, &lt;br&gt;
contact me by the 'Contact Author' link in the file &lt;br&gt;
exchange.&lt;br&gt;
regards&lt;br&gt;
Andres</description>
    </item>
    <item>
      <pubDate>Fri, 04 Jul 2008 15:27:35 -0400</pubDate>
      <title>Re: extract dynamically the headerlines row numvber by string/number</title>
      <link>http://www.mathworks.com/matlabcentral/newsreader/view_thread/171736#441200</link>
      <author>Engeltje</author>
      <description>On 2 Lug, 15:23, &quot;Andres &quot; &amp;lt;rant...@werb.de&amp;gt; wrote:&lt;br&gt;
&amp;gt; Engeltje &amp;lt;Engeltj...@gmail.com&amp;gt; wrote in message &amp;lt;cb6bb0d2-&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; fbf2-4fbf-9ec2-d636a39e3...@p25g2000hsf.googlegroups.com&amp;gt;...&lt;br&gt;
&amp;gt; [..]&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; if u want to have an idea...if u give me ur emali address&lt;br&gt;
&amp;gt; I will send&lt;br&gt;
&amp;gt; &amp;gt; it!&lt;br&gt;
&amp;gt; &amp;gt; let me know!!&lt;br&gt;
&amp;gt; &amp;gt; regards angelo&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt; i have just sent you an email. If that does not work,&lt;br&gt;
&amp;gt; contact me by the 'Contact Author' link in the file&lt;br&gt;
&amp;gt; exchange.&lt;br&gt;
&amp;gt; regards&lt;br&gt;
&amp;gt; Andres&lt;br&gt;
&lt;br&gt;
Andres...Eureka!!!!!:-D&lt;br&gt;
I finally found a solution.....&lt;br&gt;
reading the file with xlsread.....sometimes solution is easier then&lt;br&gt;
one can think!!!!We look for difficult solution!!!!&lt;br&gt;
Angelo&lt;br&gt;
Thx so much</description>
    </item>
  </channel>
</rss>

