[Limdep Nlogit List] Pseudo R-squared

Richard Hofler rhofler at bus.ucf.edu
Fri Jun 16 21:06:08 EST 2006


Marc,

The commands below work when using the TUCE data that is available in LIMDEP 8.0 Help.

Richard


Read	;Nobs = 32	;Nvar = 5
	;Names = 
OBS,  GPA, TUCE, PSI, GRADE  $

1	2.66	20	0	0		
2	2.89	22	0	0		
3	3.28	24	0	0		
4	2.92	12	0	0		
5	4	21	0	1		
6	2.86	17	0	0		
7	2.76	17	0	0		
8	2.87	21	0	0		
9	3.03	25	0	0		
10	3.92	29	0	1		
11	2.63	20	0	0		
12	3.32	23	0	0		
13	3.57	23	0	0		
14	3.26	25	0	1		
15	3.53	26	0	0		
16	2.74	19	0	0		
17	2.75	25	0	0		
18	2.83	19	0	0		
19	3.12	23	1	0		
20	3.16	25	1	1		
21	2.06	22	1	0		
22	3.62	28	1	1		
23	2.89	14	1	0		
24	3.51	26	1	0		
25	3.54	24	1	1		
26	2.83	27	1	1		
27	3.39	17	1	1		
28	2.67	24	1	0		
29	3.65	21	1	1		
30	4	23	1	1		
31	3.1	21	1	0		
32	2.39	19	1	1		


?===================================================================
?  Compute a Pseudo Rsquared for a probit model based on the       
?  McKelvey and Zavoina's formula in their paper on the ordered     
?  probit model.  The formula suggested is                                 
?                                                                          
?         E[y*|y]  =  yf  =  beta'x  +  lambda                                
?                                                                          
?         Rý = N * [ var(yf) / (1 + var(yf) ]                              
?                                                                          
?  where  lambda is the inverse Mill's ratio usually kept for SELECT.      
?  (To get the MZ result exactly, we'd use 1/N not 1/(N-1) in var(yf).)    
? User must define the data matrix with the following line:        
?                                                                        
?       NAMELIST	; X = . . .  $                              
?                                                                  
? User's dependent variable is Y.  Change the following line       
?                                                                  
?        CREATE           ; Y = the dependent variable $           
?                                                                          
?===================================================================
? Using the above data and the following commands, I get 
?     ZM      =  .62678097487339320D+00

NAMELIST	; X = one, GPA, TUCE, PSI $                              
   
PROBIT   	; lhs = GRADE ; rhs = X ; hold(imr=lambda) $                       

CREATE   	; yf = x'b + lambda $                                     
CALC     	; list ; zm = (n-1)*var(yf) / (n + (n-1)*var(yf)) $                   

Richard A. Hofler
Professor 
Office: BA2 302F
Voice: (407) 823-2606



-----Original Message-----
From: limdep-bounces at limdep.itls.usyd.edu.au [mailto:limdep-bounces at limdep.itls.usyd.edu.au] On Behalf Of Marc Goergen
Sent: Thursday, June 15, 2006 9:56 AM
To: Limdep Discussion List
Subject: [Limdep Nlogit List] Pseudo R-squared

Dear all,

I am trying to estimate the McKelvey and Zavoina pseudo R-squared for an ordered probit model.

I am following the procedure as stated in the online help file. However, when I do the calculations, Limdep overwrites the first 12 rows of my data file. Does anybody know what is going on?

This is the procedure I am using:

?===================================================================
?  Compute a Pseudo Rsquared for a probit model based on the       
?  McKelvey and Zavoina's formula in their paper on the ordered     
?  probit model.  The formula suggested is                                 
?                                                                          
?         E[y*|y]  =  yf  =  beta'x  +  lambda                                
?                                                                          

?         Rý = N * [ var(yf) / (1 + var(yf) ]                              
?                                                                          
?  where  lambda is the inverse Mill's ratio usually kept for SELECT.      
?  (To get the MZ result exactly, we'd use 1/N not 1/(N-1) in var(yf).)    
? User must define the data matrix with the following line:        
?                                                                  
?        NAMELIST         ; X = ... $                              

?                                                                  
? User's dependent variable is Y.  Change the following line       
?                                                                  
?        CREATE           ; Y = the dependent variable $           
?                                                                          
?===================================================================
   PROBIT   ; lhs = y ; rhs = X ; hold(imr=lambda) $                       

   CREATE   ; yf = x'b + lambda $                                     
   CALC     ; list ; zm = (n-1)*var(yf) / (n + (n-1)*var(yf)) $                   
_______________________________________________
Limdep site list
Limdep at limdep.itls.usyd.edu.au
http://limdep.itls.usyd.edu.au



More information about the Limdep mailing list