[Limdep Nlogit List] Looping successive bivariate probit estimations.
Arthur Caplan
arthur.caplan at usu.edu
Wed Apr 1 01:36:54 EST 2009
Hi Bill,
I just added the comment lines in the email message to annotate my thinking concerning the code. I generally don't use line-by-line comments in the code itself (although I'm now thinking that's a habit I should adopt).
It doesn't appear that I have the option to double click the matrix's name in the output window, as I do, say, with the "Matrix: LastOutp" matrices of the estimation results from the runs of the regressions. Which leads me to believe that the matrix I ultimately want listed (biprobb) isn't being compiled in the first place.
Arthur
-----Original Message-----
From: limdep-bounces at limdep.itls.usyd.edu.au [mailto:limdep-bounces at limdep.itls.usyd.edu.au] On Behalf Of William Greene
Sent: Tuesday, March 31, 2009 12:23 AM
To: Limdep and Nlogit Mailing List
Subject: Re: [Limdep Nlogit List] Looping successive bivariate probit estimations.
Arthur. I don't think you turned the output back on after the comment
line. /******* etc. is not followed by a line with */ in it.
This is a little tricky. I would use ?******** ... for one line comments.
After the proc runs, you can double click the matrix's name in the project
window to see if it was computed correctly.
/Bill Greene
----- Original Message -----
From: "Arthur Caplan" <arthur.caplan at usu.edu>
To: limdep at limdep.itls.usyd.edu.au
Sent: Monday, March 30, 2009 6:13:52 PM GMT -05:00 US/Canada Eastern
Subject: [Limdep Nlogit List] Looping successive bivariate probit estimations.
Dear Limdep users,
I'm basically a novice with a novice-type coding problem. I'm using Limdep 8.0 (Nlogit 3.0) and trying to run successive bivariate probit regressions, where a collection of pairwise sets of dependent variables are successively regressed against a given set of independent variables. My goal is to ultimately build what amounts to a matrix of bootstrapped coefficient estimates so that I can calculate the associated standard deviations as estimates of their bootstrapped standard errors.
Here is the code I'm using for this exercise:
/********Initial univariate probit models to set starting values********/
/*******Round 1*******/
sample;all$
namelist; y1=y11,y21, y31; y2=y12,y22, y32; x=hyp,info,bid$
matrix;r1b=init(3,4,0)$ /*Note: The 3 denotes three runs of the regression and the 4 denotes four coefficients being estimated */
proc
Probit;lhs=y1:i;rhs=one,x$
matrix;r1b(i,*)=b$
endproc
execute;Silent;i=1,3$
list;r1b$
/*******Round 2*******/
sample;all$
matrix;r2b=init(3,4,0)$
proc
Probit;lhs=y2:i;rhs=one,x$
matrix;r2b(i,*)=b$
endproc
execute;Silent;i=1,3$
list;r2b$
/**********Bivariate Probit Model Estimation***********/
sample;all$
matrix;biprobb=init(8,3,0)$
proc
skip$
bivariate probit; lhs=y1:i,y2:i; rh1=one,x; rh2=one,x; start=r1b,r2b$
matrix;biprobb(i,*)=b$
endproc
execute;i=1,3$
list;biprobb$
stop$
The program runs just fine, i.e., it calculates everything for the univariate probit models and it runs the successive three bivariate probit regressions. However, when it comes to listing the coefficient matrix for the bivariate regressions, i.e., listing matrix biprobb, it stops, providing no specific error message. In the output file Limdep acts like it wants to list the matrix, but never does.
Any insight would be appreciated.
Arthur Caplan
_______________________________________________
Limdep site list
Limdep at limdep.itls.usyd.edu.au
http://limdep.itls.usyd.edu.au
_______________________________________________
Limdep site list
Limdep at limdep.itls.usyd.edu.au
http://limdep.itls.usyd.edu.au
More information about the Limdep
mailing list