Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!k19g2000yqc.googlegroups.com!not-for-mail
From: Rune Allnor <allnor@tele.ntnu.no>
Newsgroups: comp.soft-sys.matlab
Subject: Re: read large text files
Date: Tue, 27 Oct 2009 23:32:03 -0700 (PDT)
Organization: http://groups.google.com
Lines: 16
Message-ID: <1805d2f8-85d2-489a-848c-fa3f6aecf463@k19g2000yqc.googlegroups.com>
References: <hc85sr$f4q$1@fred.mathworks.com>
NNTP-Posting-Host: 77.16.79.233
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
X-Trace: posting.google.com 1256711524 15679 127.0.0.1 (28 Oct 2009 06:32:04 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Wed, 28 Oct 2009 06:32:04 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: k19g2000yqc.googlegroups.com; posting-host=77.16.79.233; 
	posting-account=VAp5gAkAAAAmkCze5hvZtMeedpZWNthI
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; 
	Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; 
	.NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 1.1.4322),gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:580527


On 28 Okt, 02:14, "Anandhi " <anan...@mathworks.com> wrote:
> Hi ,
>
> I have text files having 6 columns of data, but the number of rows is greater than 100000. I do not know the exact row number.
>
> When I use this prog I am able to get upto 100000 rows. How to get the rows beyond this till the end of file?

This is a trivial programming exercise on buffered I/O:

1) Decide on a buffer size
2) Clear block, set block ponter to star of buffer
3) Read till buffer is full or EOF is found
4) Process data
5) If EOF not yet found, repeat from 2)

Rune