[R] R-help Digest, Vol 107, Issue 14
Paul Gilbert
pgilbert902 at gmail.com
Mon Jan 16 00:14:51 CET 2012
On 12-01-14 06:00 AM, r-help-request at r-project.org wrote:
> Date: Fri, 13 Jan 2012 02:09:09 -0800 (PST)
> From: statquant2<statquant at gmail.com>
> To:r-help at r-project.org
> Subject: Re: [R] simulating stable VAR process
> Message-ID:<1326449349804-4291835.post at n4.nabble.com>
> Content-Type: text/plain; charset=us-ascii
>
> Hello Paul
> Thanks for the answer but my point is not how to simulate a VAR(p) process
> and check that it is stable.
> My question is more how can I generate a VAR(p) such that I already know
> that it is stable.
Just to be clear, my answer was telling you how to check that the model
is stable, not how to simulate a process and check if the process is
stationary, which is probably what you mean when you say stable process.
Beware that the terminology "stable model" is often used nowadays to
refer to whether the parameters are changing over time. This has little
to do with whether the model is stable in the sense of the modulus of
the determinant of the polynomial. Elsewhere in this thread, I think
John Frain has given you an algorithm for generating models.
> We know a condition that assure that it is stable (see first message) but
> this is not a condition on coefficients etc...
Yes, it is a condition on coefficients.
> What I want is
> generate say a 1000 random VAR(3) processes over say 500 time periods that
> will be STABLE (meaning If I run stability() all will pass the test)
I am a bit confused by what you mean here. If you are saying "generate
500 time periods for each of the 1000 models", you do not have to
generate any time periods unless you want simulated data, you can check
if the models are stable directly, because this is a check on the
coefficients of the model. [If you are saying that the model is changing
over time, then the models may all individually be stable in the
determinant sense, but this is not stable (by construction) in the
second sense above. And, the generated process will probably not be
stationary according to many of the usual definitions.]
>
> When I try to do that it seems that none of the VAR I am generating pass
> this test, so I assume that the class of stable VAR(p) is very small
> compared to the whole VAR(p) process.
When you say "small" I think you are talking about a measure on the
space of coefficients. If you use the usual metric and generated the
coefficients uniformly randomly over R^n, then the models that have
determinant inside the unit ball would probably be a very small set.
Even with considerable restrictions, say for example, the coefficients
all between -1 and 1, I think the stable models would be a small set.
HTH,
Paul
>
>
> --
> View this message in context:http://r.789695.n4.nabble.com/simulating-stable-VAR-process-tp4261177p4291835.html
> Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list