Hi all.
I would like every working day to import a file using read.table.
The file will be in D:\\DATA\\2001\\
and it will be named as the paste of "dat", of the current date
(yymmdd) and the ".txt" extension. The name of the object will
be the paste of "dat" and the current date.
for example:
current <- "dat010222.txt"
filename <- paste("D:\\DATA\\2001\\", current, sep="")
dat010222 <- read.table(filename,header = TRUE, sep = c(1, 11, 21, 31 ,
41),skip=1)
Is there a way for this to be done automatically for each new day,
using a function like date()?
Any suggestion is highly appreciated.
Thanks.
Spyros.
|