So many matrices are square symmetrical (i.e. variance-covariance matrices),
is there any way to get R to split the matrix on its diagonal and just
return one diagonal?

 

So if I have

 

mat<-matrix(c(1,4,3,4,1,2,3,2,1), nrow = 3, ncol=3, byrow=TRUE)

 

is there anyway to get the lower right diagonal instead of the entire
symmetric matrix?

 

-------------------------------------------

Joe King, M.A.

Ph.D. Student 

University of Washington - Seattle

206-913-2912  

 <mailto:j...@joepking.com> j...@joepking.com

-------------------------------------------

Ad astra per aspera  - "Through hardships to the stars"

 


        [[alternative HTML version deleted]]

______________________________________________
R-help@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.

Reply via email to