[R] square root of inverse

baptiste auguie baptiste.auguie at googlemail.com
Thu Apr 8 17:40:31 CEST 2010


try this,

install.packages("expm", repos="http://R-Forge.R-project.org")

On 8 April 2010 17:28, arindam fadikar <arindam.fadikar at gmail.com> wrote:
> On Thu, Apr 8, 2010 at 5:38 PM, David Winsemius <dwinsemius at comcast.net>wrote:
>
>>
>> On Apr 8, 2010, at 1:45 AM, arindam fadikar wrote:
>>
>>  Dear users,
>>>
>>> How to get a symmetric square root of a positive definite matrix? I have
>>> tried using spectral decomposition, but some eigen values come out to be
>>> complex. Is there any function in R that can give the symmetric square
>>> root
>>> of a pd matrix?
>>>
>>>
>> require(expm)
>> ?sqrtm
>>
>>
>> expm is not a package, but a function which gives  exp of a matrix, and i
> dont get any result from ?sqrtm. Please help.
>
>>  --
>>> Arindam Fadikar
>>> M.Stat
>>> Indian Statistical Institute.
>>> New Delhi, India
>>>
>>>        [[alternative HTML version deleted]]
>>>
>>> ______________________________________________
>>> R-help at r-project.org mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>> PLEASE do read the posting guide
>>> http://www.R-project.org/posting-guide.html
>>> and provide commented, minimal, self-contained, reproducible code.
>>>
>>
>> David Winsemius, MD
>> West Hartford, CT
>>
>>
>
>
> --
> Arindam Fadikar
> M.Stat
> Indian Statistical Institute.
> New Delhi, India
>
>        [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



More information about the R-help mailing list