Re: [R] convering upper triangular matrix into vector

From: Dimitris Rizopoulos <dimitris.rizopoulos_at_med.kuleuven.be>
Date: Sun 02 Oct 2005 - 20:24:56 EST

look at: '?upper.tri()'

Best,
Dimitris



Dimitris Rizopoulos
Ph.D. Student
Biostatistical Centre
School of Public Health
Catholic University of Leuven

Address: Kapucijnenvoer 35, Leuven, Belgium

Tel: +32/(0)16/336899
Fax: +32/(0)16/337015
Web: http://www.med.kuleuven.be/biostat/
     http://www.student.kuleuven.be/~m0390867/dimitris.htm


> Hi
>
> I have two symmetrical distance matrices and want to compute the
> correlation
> coefficient between them (after turning them into vectors).
>
> Is there a way of selecting only the upper triangular part of each
> matrix, then
> convert this into a vector so I can compute the correlation?
>
> Many Thanks
> Eleni Rapsomaniki
>
> ______________________________________________
> R-help@stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>

Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Sun Oct 02 20:26:08 2005

This archive was generated by hypermail 2.1.8 : Sun 23 Oct 2005 - 18:08:22 EST