Re: [R] accessing files from subfolders

2011-06-08 Thread Henrique Dallazuanna
Try this: lapply(dir("myPathDir", recursive = TRUE, pattern = "myFile.txt$", full.names = TRUE), readLines, warn = FALSE) On Wed, Jun 8, 2011 at 6:35 PM, J wrote: > Hi, >   There must be an easy way to do this, but I'm not finding it.. > > I'd just like to know the syntax to move up and down fol

Re: [R] accessing files from subfolders

2011-06-08 Thread Duncan Murdoch
On 11-06-08 5:35 PM, J wrote: Hi, There must be an easy way to do this, but I'm not finding it.. I'd just like to know the syntax to move up and down folder levels, without necessarily entering a full file path. Also, how to construct file and folder paths using variables. For example 1,