Skip to content
Prev 71052 / 398500 Next

ts.intersect a multivariate and univariate ts

Andy:
Providing a reproducible example would be a first step...

For me the following works without any problems:

R> pg <- ts(matrix(rnorm(22 * 12), ncol = 12), start = 1982)
R> rw <- ts(rnorm(307), start = 1690)
R> tsp(pg)
[1] 1982 2003    1
R> dim(pg)
[1] 22 12
R> tsp(rw)
[1] 1690 1996    1
R> rwpg <- ts.intersect(rw, pg)
R> tsp(rwpg)
[1] 1982 1996    1
R> dim(rwpg)
[1] 15 13

Best,
Z