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: Generating intermediate output with a program that calls a mata function


From   Matthew Baker <[email protected]>
To   [email protected]
Subject   Re: st: Generating intermediate output with a program that calls a mata function
Date   Wed, 18 Jul 2012 20:16:57 -0400

Daniel --

Thanks very much - that seems to do the trick! And it is much more
elegant and consistent with the spirit of mata than the approach which
I was using, which was to insert in the mata code a call to stata,
like:

stata(`"display "." _continue"')

which also seemed to do the trick.

Thanks again,

Matt Baker

On Wed, Jul 18, 2012 at 5:19 PM, daniel klein
<[email protected]> wrote:
> Matt,
>
> instead of
>
> printf("Case done")
>
> try
>
> printf("Case done \n")
> displayflush()
>
> This is documented in -help mata printf-
>
> "One of the purposes of the iteration output is to keep the user
> informed that the code is indeed working, yet as the above code is
> written, the user probably will not see the iteration messages as they
> occur.  Instead, nothing will appear for a while, and then,
> unexpectedly, numerous iteration messages will appear as Stata,
> buffers full, decides to send to the terminal the waiting output.
>
> To force output to be displayed, use [M-5] displayflush():"
>
> Best
> Daniel
> *
> *   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/



-- 
Dr. Matthew J. Baker
Department of Economics
Hunter College and the Graduate Center, CUNY
*
*   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