[R] ts.union and tsp

Roger Bivand Roger.Bivand at nhh.no
Wed Jan 15 11:19:05 CET 2003


On Wed, 15 Jan 2003, Dieter Menne wrote:

> I don't understand the following behavior of ccf
> 
> library(ts)
> a<-runif(100)
> b<-runif(100)

Maybe:

> a <- ts(runif(100))
> b <- ts(runif(100))

acf() converts the input vector to the needed class, ccf() doesn't.

> 
> acf(a) # works
> ccf(a,b) # fails
> 
> #.. because of the following 
> ts.union(a,b)
> 
> # which fails on tsp(x) in .cbind.ts 
> #tsser <- sapply(sers, function(x) length(tsp(x)) > 0)
> 
> 
> (R 1.6.1, Windows)
> 
> Dieter Menne
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> http://www.stat.math.ethz.ch/mailman/listinfo/r-help
> 

-- 
Roger Bivand
Economic Geography Section, Department of Economics, Norwegian School of
Economics and Business Administration, Breiviksveien 40, N-5045 Bergen,
Norway. voice: +47 55 95 93 55; fax +47 55 95 93 93
e-mail: Roger.Bivand at nhh.no




More information about the R-help mailing list