From plummer@iarc.fr  Thu May 13 10:36:52 1999
From: plummer@iarc.fr (Martyn Plummer)
Date: Thu, 13 May 1999 11:36:52 +0200
Subject: yet another ts problem
References: <Pine.BSF.4.05.9905131005150.525-100000@g.ihaka.slip.auckland.ac.nz>
Message-ID: <373A9D34.EE7511F9@iarc.fr>

Ross Ihaka wrote:

> 1. I think that "[.ts" tries too hard to turn its value back into
>    a time series.  The only case where this makes sense is when
>    a selection of columns is taken from a multivariate series.
>    If a row subset is taken, it can only be a time series if
>    the subscripts have a very special pattern.  This would be
>    too expensive I think.
> 
>    In S there is no "[.ts", and a simple array subset is returned.

An alternative to using "[.ts" to take row subsets would be to 
expand the window.ts() function to include a "freq" or "deltat"
argument. One can then use window() to thin out a regular time series
and "[.ts" could be modified to just return a simple array subset
(in the process get rid of the horrible warning about not returning a
time series).

I already did something like this in the coda package for MCMC output -
which one often wants to thin out because of high autocorrelation.

Martyn
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._


yet another ts problem
Martyn Plummer