Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.


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

Re: st: beginer's mata function in dofile


From   daniel klein <[email protected]>
To   [email protected]
Subject   Re: st: beginer's mata function in dofile
Date   Wed, 8 Aug 2012 12:40:34 +0200

Tashi,

there is nothing I can really add to that statement. The critical
point is to define/compile the Mata function before you call it. This
do-file works, without a -program- being defined.

m :
void myfunc(real scalar x)
{
    x
}
end

loc x 42
m : myfunc(`x')

Best
Daniel

-- 
The only thing I didn't follow is where you say... it is not necessary
to define a program that calls mata functions. Could you elaborate on
that?
*
*   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–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index