| ![]() |
From | Val�rie Orozco <Valerie.Orozco@toulouse.inra.fr> |
To | statalist@hsphsun2.harvard.edu |
Subject | st: RE: define a matrix using its names of columns and rows |
Date | Wed, 02 Aug 2006 14:11:22 +0200 |
I have a matrix toto like
toto[3,2]
b1 b2
a1 0 0
a2 0 0
a3 0 0
Does anyone know how I can use the names of columns and rows of the
matrix to replace some elements.
Instead of doing mat toto[2,1] = -1, I would to write "mat toto["a2",
"b1"] = -1" (but this last one is wrong since I have the error "type
mismatch") ???
© Copyright 1996–2025 StataCorp LLC | Terms of use | Privacy | Contact us | What's new | Site index |