Path: news.mathworks.com!newsfeed-00.mathworks.com!kanaga.switch.ch!switch.ch!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsfeed.straub-nv.de!feeder.eternal-september.org!eternal-september.org!not-for-mail
From: dpb <none@non.net>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Importing text files with multiple headers
Date: Thu, 02 Jul 2009 18:46:34 -0500
Organization: A noiseless patient Spider
Lines: 17
Message-ID: <h2jh99$ij3$1@news.eternal-september.org>
References: <h2iesa$i90$1@fred.mathworks.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Trace: news.eternal-september.org U2FsdGVkX1+vcUfyfWsHikiTW0rOulK1Ou1/7cidw3MCNwOEsrdIgVOl/OXVFN3pLB2VvCMFirqTGndQsFyNcQP7P3FurxYJVfJME/ChrR/AqYVQsP0sIUae3aSgVXXPP9LRfo7P1oqtM/YNEFiv0g==
X-Complaints-To: abuse@eternal-september.org
NNTP-Posting-Date: Thu, 2 Jul 2009 23:53:14 +0000 (UTC)
In-Reply-To: <h2iesa$i90$1@fred.mathworks.com>
X-Auth-Sender: U2FsdGVkX1/nvzMdwj3Yl53eL4a43+ebeLa/g0EAhu8=
Cancel-Lock: sha1:PWajNB/B8vWctCtPSH5dCapbyu0=
User-Agent: Thunderbird 2.0.0.21 (Windows/20090302)
Xref: news.mathworks.com comp.soft-sys.matlab:552579


Leo Steenson wrote:
> I am trying to import text files into matlab.  The problem is that
> within the files there is a text header then some numerical data then
> header, data, header etc.
...
> Does anyone know of a command to ignore all lines of text and only
> import the data, specifically when the data is interupted through the
> file with words.
...
Not a prebuilt function, no--you can do the same thing as you're 
presently doing except at a lower level w/ fgetl(), fread(), sscanf(), 
strread() and friends to handle your file structure, however.

Whether there's a more general version of textread() et al. at the file 
exchange that could help might be worth a look-see...

--