[R] Opening all files in a directory

Peter Dalgaard BSA p.dalgaard at biostat.ku.dk
Wed Jun 12 18:37:45 CEST 2002


"MATT BORKOWSKI" <mpb170 at psu.edu> writes:

> Is there any way that R can be programmed so that it will cycle through 
> all files in a directory without having to define file names?  The reason I ask
> is because I will have about 50-100 files in a directory which will be randomly
> named.  ie:  MIDEX, OACES-CO2, ODEN91, etc...  
> 
> If not...are there any languages out there that will do this sort of things?  Or is
> there another method you could recommend for handling the problem?

For what purpose? Will "for (i in list.files(....)) ..."  do?

-- 
   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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list