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: CMP Error Message


From   William Buchanan <william@williambuchanan.net>
To   "statalist@hsphsun2.harvard.edu" <statalist@hsphsun2.harvard.edu>
Subject   Re: st: CMP Error Message
Date   Sat, 23 Mar 2013 16:01:55 -0700

You could also try running the command with -set trace on- so you can find out where things are breaking down.

Sent from my iPhone

On Mar 23, 2013, at 15:53, Jeffrey Ferris <ferrij492@gmail.com> wrote:

> I am using the most recent version, perhaps this is the issue. This
> might also explain why the program would work on Thursday and not
> since that time, because I have updated the program in that time. It
> is a bit of a relief to know that this error is (most likely) not
> caused by a problem on my end because I am out of troubleshooting
> ideas. As per your advice, I will email David Roodman next to see if
> he has any suggestions.
> 
> Thank you very much for your help,
> 
> Jeff
> 
> On Sat, Mar 23, 2013 at 4:24 PM, William Buchanan
> <william@williambuchanan.net> wrote:
>> Which version of -cmp- are you using? David Roodman released an update to the program only a few days ago and maybe something is different.
>> 
>> Sent from my iPhone
>> 
>> On Mar 23, 2013, at 12:34, John Luke Gallup <jlgallup@pdx.edu> wrote:
>> 
>>> Jeffrey,
>>> 
>>> This is pretty clearly a bug in -cmp-, where the Mata function cmp_lnL() is probably calling the function l(), which cannot handle the value of its argument.  This is not likely to be a problem you can fix, unless you are not using -cmp- correctly.  In any case, a program like -cmp- should ideally trap user errors rather than crashing.
>>> 
>>> It is a little mysterious why -cmp- produced this error message when it apparently didn't during an identical previous run, but almost certainly something changed from one run to the next.
>>> 
>>> I think your best bet is to contact the author of -cmp-, David Roodman (see the end of the -cmp- help file for his email address), and politely ask for help.
>>> 
>>> John
>>> 
>>> On Mar 23, 2013, at 8:32 AM, Jeffrey Ferris <ferrij492@gmail.com> wrote:
>>> 
>>>> Hello,
>>>> 
>>>> I am working with the user generated command CMP and I am having a
>>>> strange problem that I am unable to diagnose. I am trying to estimate
>>>> a system of equations with one probit equation and two mprobit
>>>> equations (with no overlap between the multinomial models). Every time
>>>> I try to run the model it proceeds normally until it tries to collect
>>>> Halton draws and gives me the following error message:
>>>> 
>>>> "I():  3300  argument out of range
>>>>             cmp_lnL():     -  function returned error
>>>>               <istmt>:     -  function returned error
>>>> Mata run-time error"
>>>> 
>>>> The strange thing is that I ran the exact same code Thursday night and
>>>> it worked without problem. I have gone through every line of my code
>>>> and cannot see what could be causing this failure. I also double
>>>> checked that cmp is working correctly by running it with some older
>>>> models without failure. Does anybody have any idea what could be going
>>>> on or, more importantly, how I can rectify this problem? For those
>>>> interested, here are the commands I used to generate this output:
>>>> 
>>>> gen ind1=cond(treat_t==0,$cmp_mprobit,$cmp_out)
>>>> gen ind2=cond(treat_t==1,$cmp_mprobit,$cmp_out)
>>>> local 2step_m DstCityBdr_avg DistRds_avg DistIntHwy lntotstream_dens ///
>>>> lnsubdivarea existhouse MeanElev_avg MeanSlope_avg ///
>>>> Area100yr_dens depwat_avg hydgrp_C hydgrp_D
>>>> foreach class in RC4 RC2 {
>>>> local zone_int_rc `zone_int_rc' zone_`class' c.treat_t#c.zone_`class'
>>>> }
>>>> cmp (y= `zone_int_rc' minor_exempt_RC treat_t `2step_m' `years`i'') ///
>>>> (zone_class= `2step_m' DistRiver_avg DistPStrm_avg DistIStrm_avg
>>>> Watershed2-Watershed15, iia) ///
>>>> (zone_class= `2step_m' DistRiver_avg DistPStrm_avg DistIStrm_avg
>>>> Watershed2-Watershed15, iia) ///
>>>> if `timeline`i'' & RCsum>0.5, difficult indicators($cmp_probit ind1 ind2) ///
>>>> tech(dfp nr) cluster(ind) robust ghkdraws(10)
>>>> outreg2 using cmp_rc`i'.csv, replace dec(3)
>>>> 
>>>> Thank You,
>>>> 
>>>> Jeff Ferris
>>>> *
>>>> *   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/
>>> 
>>> 
>>> *
>>> *   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/
>> 
>> *
>> *   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/
> 
> 
> 
> --
> Jeffrey Ferris
> PhD Student
> University of Maryland, College Park
> Agriculture and Resource Economic Consortium
> 
> *
> *   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/

*
*   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