Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Mata


From   "Raphael Fraser" <[email protected]>
To   [email protected]
Subject   st: Mata
Date   Tue, 22 Jan 2008 17:38:53 -0500

Can anyone explain why the matrix X gives the incorrect result?
When I run the code and check the contents of the matrix A and F.
A is the matrix view of amt.csv but A is also the view of the same file.
At some point the matrix F becomes A. What's the problem?

***begin here***
mata clear
stata("insheet using freq.csv, clear")
stata("drop subjectid")
st_view(F=., ., .)                            /* 91 subjects x 110 foods */

stata("insheet using amt.csv, clear")
stata("drop subjectid")
st_view(A=., ., .)                           /* 91 subjects x 110 foods */
X = 0.01*(A:*F)
***end here***

Raphael
*
*   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