Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: extracting diagonal elements from a matrix


From   Kate Ivanova <[email protected]>
To   [email protected]
Subject   st: RE: extracting diagonal elements from a matrix
Date   Sun, 17 Apr 2005 13:48:05 -0700

Sorry, figured it out myself. I could not find 'vecdiag' function before,
but now I have. Thanks, anyway.

Kate

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Kate Ivanova
Sent: Saturday, April 16, 2005 10:18 PM
To: [email protected]
Subject: st: extracting diagonal elements from a matrix

Hi,

I am using Stata 7 and have to create two new variables out of a square
matrix:

1) one variable consisting of the diagonal elements of a matrix
2) the other variable consisting of the row sum of all the elements
excluding the diagonal one

I would really appreciate any help with that.

Kate

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index