Re: [R] Reading fixed column format

From: Jason Barnhart <jasoncbarnhart_at_msn.com>
Date: Mon 11 Sep 2006 - 16:39:25 GMT

Not familiar w/ Stata, but these functions read data files and should provide the functionality you wish.

?read.fwf
?read.table
?scan

> How can I read fixed column data (without a delimiter) from a large ASCII
> file
> directly into R? I want to read non-contiguous variables. I am trying to
> avoid
> reading it first into a DBMS and then choosing the variables. I would
> perfer to
> format and label it along while reading if possible. Something like what
> STATA
> does with dictionary. Anupam.
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue Sep 12 02:44:39 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Mon 11 Sep 2006 - 18:30:04 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.