Message-ID: <CAHFjiEB2j2wWPLBkt9TBrsgJu=4zhqF+MbnhC6gU1EFWjEjXNA@mail.gmail.com>
Date: 2012-08-12T18:46:34Z
From: Boel Brynedal
Subject: Problem when creating matrix of values based on covariance matrix
In-Reply-To: <CAHFjiEABCTEbntmJAsZhekjAO4-JA5rj6S1e31OdXCSha7Ligg@mail.gmail.com>
A clarification - yes, calculating the pearson covariance does give
the expected results. I dont fully understand why yet, but many thanks
for this help!
2012/8/12 Boel Brynedal <brynedal at gmail.com>:
> Thanks for these replies.
> @Peter - are these methods only suitable for pearson covariances? That
> would def explain my issues. Sorry for my ignorance, but I would
> highly appreciate an explanation. My original covariance matrix is
> calculated using spearman as well (which is suitable for the data).
> @Michael - I am simulating a sample size of 20351* 8368 so I do not
> think that the sample size is the issue here.
>
> 2012/8/12 peter dalgaard <pdalgd at gmail.com>:
>>
>> On Aug 11, 2012, at 16:17 , Boel Brynedal wrote:
>>
>>> cov8=cov(sample8,method='spearman')
>>
>> There's your problem. I'm surprised that nobody seems to have picked up on this, but Spearman covariances are of the ranks, not of the data. Try method="pearson".
>>
>> --
>> Peter Dalgaard, Professor,
>> Center for Statistics, Copenhagen Business School
>> Solbjerg Plads 3, 2000 Frederiksberg, Denmark
>> Phone: (+45)38153501
>> Email: pd.mes at cbs.dk Priv: PDalgd at gmail.com
>>
>>
>>
>>
>>
>>
>>
>>