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, is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: bootstrapping when setting cmd in an ado file

From   Matthias Schonlau <>
Subject   st: bootstrapping when setting cmd in an ado file
Date   Thu, 22 Jul 2010 13:44:45 +0200

Dear statalisters,

(Using stata Version 10.1, Windows, 32 bit)

I wrote a (long) ado file called rds. One of the functions inside the ado 
file sets cmd: 
        ereturn local cmd="bootstrap"

If I set cmd="bootstrap", the program and bootstrapping the program work 
However, I believe  cmd should be set to the ado program name 

        ereturn local cmd="rds"

When I do this , the program rds works , but bootstrapping rds does not 

. bootstrap _b ,   reps(2500) notable  : rds key, id(id) degree(degree) 
recruiter_id(p_id) recruiter_var(p_key) 
(running rds on estimation sample)
variable degree not found in option degree()
an error occurred when bootstrap executed rds

Two comments:
1) the option "degree" specifies the name of a variable in the data set. I 
am not sure whether this matters.
2) As required, I am setting "esample" 
        gen esample =`touse'
        ereturn post b, esample (esample)

I would greatly appreciate any comments. 

Best wishes, 


Matthias Schonlau, Ph.D. 
German Institute for Economic Research (DIW)
RAND Corporation, Pittsburgh, PA , USA

Phone (49) 30 -89789 - 319
Mail: DIW Berlin, 10108 Berlin, Germany

*   For searches and help try:

© Copyright 1996–2016 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index