Message-ID: <1264361699240-1288816.post@n4.nabble.com>
Date: 2010-01-24T19:34:59Z
From: Brad Patrick Schneid
Subject: read multiple large files into one dataframe
In-Reply-To: <7A84E5CF-4139-49C9-91DA-E2FE65A03423@exeter.ac.uk>
### The following is very helpful #########
listOfFiles <- list.files(pattern= ".txt")
d <- do.call(rbind, lapply(listOfFiles, read.table))
###############################
but what if each file contains information corresponding to a different
subject and I need to be able to tell where each row came from? i.e.: I
need a new row that repeats the original filename for each observation of
the former respective files.
Any ideas?
--
View this message in context: http://n4.nabble.com/read-multiple-large-files-into-one-dataframe-tp891835p1288816.html
Sent from the R help mailing list archive at Nabble.com.