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 at the end of May, and its replacement, statalist.org is already up and running.


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

Re: st: Re: export matrix from mata to stata


From   Wu Zhang <wuzhang50@yahoo.com>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: Re: export matrix from mata to stata
Date   Fri, 5 Apr 2013 00:46:40 -0700 (PDT)

Hi Joseph,

It works. Thank you very much!


Wu



----- Original Message -----
From: Joseph Coveney <stajc2@gmail.com>
To: statalist@hsphsun2.harvard.edu
Cc: 
Sent: Thursday, April 4, 2013 11:29 PM
Subject: st: Re: export matrix from mata to stata

Wu Zhang wrote:

   Could you someone help me export matrix from mata to stata? I know the other
way around: st_matrix, but do not know how to export from mata.

--------------------------------------------------------------------------------

It's the same function.  Use it as a void function.

Joesph Coveney

. mata:
--------------- mata (type end to exit) ---------------
: A = (0, 0 \ 1, 1)

: st_matrix("StataMatrix", A)

: end

-------------------------------------------------------

. matrix list StataMatrix

StataMatrix[2,2]
    c1  c2
r1   0   0
r2   1   1



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


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


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