[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Multivariate student t: normalization in mvtrnd
From: |
Arno Onken |
Subject: |
Re: Multivariate student t: normalization in mvtrnd |
Date: |
Tue, 27 Nov 2012 08:52:44 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0.10) Gecko/20121027 Icedove/10.0.10 |
Hi Iñigo,
On 11/26/12 23:06, Iñigo Urteaga wrote:
> I am using the mvtrnd function provided in the statistics package for
> octave and I have encountered some inconsistent results that I do not
> comprehend.
>
>>From theory, we know that if Z is a standard Student's t random vector
> and we define X as a linear combination (i.e. X=Sigma * Z), the
> resulting variable X is a multivariate Student's t distribution with
> covariance matrix Var(X)=nu/(nu-2)*V, where V=Sigma * Sigma'.
>
> In fact, when we define a V and sample from the following expression,
> where Sigma=chol(V), n is the dimensionality, nu the degrees of
> freedom and M the number of samples:
>
> samples=Sigma' * mvtrnd( eye(n), nu, M)'; (1)
>
> the covariance computed from those samples (i.e. cov(samples) )
> matches the expected variance nu/(nu-2)*V.
>
> However, if we directly apply:
>
> samples=mvtrnd(V, nu); (2)
>
> then, the covariance computed does not match nu/(nu-2)*V, but the
> alternative expression using the correlation matrix R: nu/(nu-2)*R.
> Here, R is the correlation matrix as computed by
> R=V./(sqrt(diag(V)*diag(V))). The mvtrnd code indicates that the
> provided V is normalized if diagonal elements are non-unit, but I
> don't understand why this is required. In fact, sampling from the
> multivariate normal (mvnrnd called within the function) actually
> performs Cholesky decomposition of the provided V to accommodate non
> unitary covariance matrices.
>
> As I understand it, both approaches (1) and (2) should provide the
> same result (and that is the case if no normalization is performed).
> Since this is not the case, I was wondering what is the underlying
> reason for that normalization step. Am I missing something here or is
> this normalization step in mvtrnd unnecessary?
You are right in the sense that we could generate multivariate t samples
with arbitrary covariance matrix and without a subsequent rescaling by
removing the normalization step. However, that would break Matlab
compatibility. The Matlab documentation of mvtrnd specifically states
that covariance matrices are rescaled to correlation matrices by mvtrnd
(see e.g. online documentation of R2012b). mvtrnd is meant to have a
correlation matrix as its argument.
Arno
- Multivariate student t: normalization in mvtrnd, Iñigo Urteaga, 2012/11/26
- Re: Multivariate student t: normalization in mvtrnd, Jordi Gutiérrez Hermoso, 2012/11/26
- Re: Multivariate student t: normalization in mvtrnd,
Arno Onken <=
- Re: Multivariate student t: normalization in mvtrnd, Iñigo Urteaga, 2012/11/27
- Re: Multivariate student t: normalization in mvtrnd, Arno Onken, 2012/11/28
- Re: Multivariate student t: normalization in mvtrnd, Iñigo Urteaga, 2012/11/28
- Re: Multivariate student t: normalization in mvtrnd, Arno Onken, 2012/11/28
- Re: Multivariate student t: normalization in mvtrnd, Iñigo Urteaga, 2012/11/29
- Re: Multivariate student t: normalization in mvtrnd, Arno Onken, 2012/11/29