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]

Re: st: SUREG with if command.


From   David Ashcraft <ashcraftd@rocketmail.com>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: SUREG with if command.
Date   Thu, 27 Sep 2012 05:50:59 -0700 (PDT)

I have further reviewed my commands. Apparently, problem is not with the location of PERSONAL directory rather it is with the file. As I have changed the location of PERSONAL folder to D-drive. I am getting the same error message: file D:\Stata11\StataAdo\Personal\aggreg.mo not found)". Any idea, Am I missing the file or my operating system has some issue. I am using Windows XP and Stata 11.
Regards

David


----- Original Message -----
From: David Ashcraft <ashcraftd@rocketmail.com>
To: "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Cc: 
Sent: Thursday, September 27, 2012 2:57:03 PM
Subject: Re: st: SUREG with if command.

I have downloaded  -suregb- and follow the instruction given with the program: "After installing the package, give command itsp_ado to build the Mata object files." What I understand from the error message -itsp_ado is stored at c:\ado\plus. While I have my stata installed from D drive and ado files are stored at D:\Stata11\ado. How can I fix this problem without losing any content. 
Regards

David


Below is the outcome:
 itsp_ado
c:\ado\plus

. version 10.1

. mata: mata set matastrict on

. mata:
------------------------------------------------- mata (type end to exit) ----------------------------------------------------------------
: // aggreg 1.0.0  CFBaum 11aug2008
: void aggreg(string scalar vname,
>             string scalar newvname,
>                 real scalar per,
>                 string scalar op,
>                 string scalar touse)
>         {
>         real colvector mult, v1, v2
>         real matrix v3
>         if (op=="A") {
>              mult = J(per, 1, 1/per)
>         }
>         else if (op=="S") {
>              mult = J(per, 1, 1)
>         }
>         else if (op=="F") {
>                  mult = J(per, 1, 0)
>                  mult[1] = 1
>         }
>         else if (op=="L") {
>              mult = J(per, 1, 0)
>              mult[per] = 1
>         }
>         st_view(v1=., ., vname, touse)
>         st_view(v2=., ., newvname)
>         v3 = colshape(v1', per) * mult
>         v2[(1::rows(v3)), ] = v3
>         }

: end
------------------------------------------------------------------------------------------------------------------------------------------

. 
end of do-file
(note: file c:\ado\personal\aggreg.mo not found)
file c:\ado\personal\aggreg.mo could not be opened
r(603);







----- Original Message -----
From: Christopher Baum <kit.baum@bc.edu>
To: "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Cc: 
Sent: Wednesday, September 26, 2012 2:40:58 PM
Subject: Re: st: SUREG with if command.

<>
On Sep 26, 2012, at 2:33 AM, Mark wrote:

> It is indeed possible in principle to use the additional obs.  -sureg-
> and -reg3- are estimating the error components for a 2-eqn model, so the
> estimated covariance matrix is 2x2:
> 
> . qui reg3 (mpg rep78) (trunk turn), ols
> 
> . mat list e(Sigma)
> 
> symmetric e(Sigma)[2,2]
>              mpg       trunk
>  mpg   29.274269
> trunk  -5.0326348   12.233795
> 
> The above uses OLS appled to 69 obs for both equations.  If we use
> - -regress- to estimate the mpg eqn, where only 69 obs are available, we
> get the same error variance:
> 
> . qui reg mpg rep78
> 
> . di e(rmse)^2
> 29.274269
> 
> But -regress- applied to the trunk equation on its own uses all 74 obs,
> and so the error variance is different (and, since it uses more obs,
> preferable):
> 
> . qui reg trunk turn
> 
> . di e(rmse)^2
> 11.848587
> 
> In principle -sureg-/-reg3- should use the additional 5 obs when
> estimating the trunk equation.  Not to do so is throwing away
> information.


That's why I wrote -suregub-.  findit suregub

Kit

Kit Baum   |   Boston College Economics & DIW Berlin   |  http://ideas.repec.org/e/pba1.html
                             An Introduction to Stata Programming  |  http://www.stata-press.com/books/isp.html
  An Introduction to Modern Econometrics Using Stata  |  http://www.stata-press.com/books/imeus.html


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


*
*   For searches and help try:
*  http://www.stata.com/help.cgi?searchhttp://www.stata.com/support/statalist/faqhttp://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