Displaying 1 result from an estimated 1 matches for "quotedate".
2008 Jan 08
1
Error with rbind and zoo
...or so.
With a custom function myread (below), I define a vector ----- res <-
vector("list",length=length(bunchafiles)) , and read files into it ----
res <- lapply(bunchafiles, myread)
myread <- function (x) {
y <- read.csv(x, as.is=T, header=T)
if (nrow(y) > 0) {
quotedate <-
strsplit(strsplit(x,"/",fixed=T)[[1]][11],".",fixed=T)[[1]][1]
a <- rep(quotedate, nrow(y))
y <- zoo(y,a)
}
return(y)
}
I now have a list of zoo'd files. Each of them is indexed by a date
which is unique. All fine so far.
Now, I want to combine all...