On Mon, 2004-12-06 at 22:12 +0800, Hu Chen wrote:
> hi all
> If I wanna get the total number of lines in a big file without reading
> the file's content into R as matrix or data frame, any methods or
> functions?
> thanks in advance.
> Regards

See ?readLines

You can use:

length(readLines("FileName"))

to get the number of lines read.

HTH,

Marc Schwartz

______________________________________________
[EMAIL PROTECTED] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to