Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st: question RE -ml- and ancillary parameters


From   Maarten buis <[email protected]>
To   [email protected]
Subject   Re: st: question RE -ml- and ancillary parameters
Date   Tue, 15 May 2007 20:54:39 +0100 (BST)

--- Phil Schumm <[email protected]> wrote:
> I am coding an estimator for a model in which the number of ancillary
> parameters depends on the observed support of the dependent variable 
> -- very similar to an ordinal probit or logit model.  My first step  
> was to translate R code I was given which successfully estimates the 
> model into Stata (mostly into Mata); now, I would like to re- 
> implement the estimator using -ml- to explore the performance  
> differences and to access all of the -ml- related goodness (e.g.,  
> hooks for robust estimates of variance, svy capability, and  
> constrained estimation).
> 
> I have used -ml- frequently in the past, but never with a problem  
> like this.  Unfortunately, -_oprobit- and -_ologit- (the underlying  
> commands which implement -oprobit- and -ologit-) are built-in, so I  
> can't see how they handle this issue.  My first instinct would be to 
> construct an -ml model- statement programmatically based on the data 
> and then execute it.  Is this a reasonable approach, and are there  
> any practical limits to the number of ancillary parameters (i.e.,  
> equations) that can be specified this way?

I have done something like this with -dirifit-. Typically this would
require programmatically creating the call to -ml- inside your main
estimation program, and programatically creating the likelihood in you
lf program. After creating a first working draft of the program it is
probably worthwhile to spent a bit of time polishing the code for
optimal readability as these parts of your code are typically the most
difficult to read, and are most likely to require maintenance as bugs
are most likely to appear there (the two are obviously related).

Hope this helps,
Maarten 

-----------------------------------------
Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands

visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434

+31 20 5986715

http://home.fsw.vu.nl/m.buis/
-----------------------------------------


		
___________________________________________________________ 
The all-new Yahoo! Mail goes wherever you go - free your email address from your Internet provider. http://uk.docs.yahoo.com/nowyoucan.html
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index