Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: RE: AW: local vs. global macro MATA


From   "Nick Cox" <n.j.cox@durham.ac.uk>
To   <statalist@hsphsun2.harvard.edu>
Subject   st: RE: AW: local vs. global macro MATA
Date   Thu, 6 May 2010 12:39:28 +0100

I think that to get a better answer Samn needs to provide much more
detail. My guess is that at a very low level global and local macro
manipulation are closer than is obvious to users. In any case, I am
amazed that Samn thinks that a speed difference is detectable.
Regardless of that, macros and Mata don't really mix and Bill's advice
in the email Martin mentions is definitive. The key point is, or should
be, that interfacing between Stata and Mata should involve at most a few
handshakes involving macros; the time taken should be utterly trivial
and the difference between different ways of doing it even more so. 

Nick 
n.j.cox@durham.ac.uk 

Martin Weiss

Have you had a look at this recent post
http://www.stata.com/statalist/archive/2010-04/msg01775.html yet?

sun samn

   I am using MATA to do GMM; somehow I need to input a value of
parameter,
it seems like local macro setting is faster than global one.
Do you have any thoughts about this?

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/


© Copyright 1996–2014 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index