"Fitzpatrick, Denis F" <fitzpatrickd at boystown.org> writes:
> I want to read in text files, processing a line at a time in a while loop,
> and exiting the loop when the entire file has been read. The files are too
> large to suck in as a piece.
> \
> for example in :
>
> while (line.I.just.read.in != end.of.file){
> dostuff()
> }
>
> what is end.of.file?
> or what would be the functional alternative to this little snippet?
Have a peek at
help(connection)
help(readLines)
--
O__ ---- Peter Dalgaard Blegdamsvej 3
c/ /'_ --- Dept. of Biostatistics 2200 Cph. N
(*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk) FAX: (+45) 35327907
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at
stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._