Statalist The Stata Listserver


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

Re: Re: st: RE: RE: RE: list subjects with a similar value


From   Michael McCulloch <[email protected]>
To   [email protected]
Subject   Re: Re: st: RE: RE: RE: list subjects with a similar value
Date   Thu, 23 Mar 2006 11:37:40 -0800

Thank you Nick! Just what I was hoping for.

At 10:46 AM 3/23/2006, you wrote:
Neil gave some excellent advice, but he broadened the question
as well. Richard Williams pointed to some style rules, but
they say nothing about content.

What criteria you apply to do files go in a loop with what
you expect from them. A starting point is that

the same do file with
the same data and
the same Stata

should yield

the same results.

This is testable by how far you can ensure
the same results e.g. (a) from yourself, a year later (b)
from some Statafriend using Stata on a different machine.

If that sounds obvious, the crunch is in the details.

What follows are just a few remainders. Some are
counsels of perfection and, depending on what I am
doing, I often ignore them. But then if things go wrong
I also know who to blame.

0. A do file should correspond to a log that it
creates and to any datasets it creates.

1. Be careful to get a report on the data that will
identify what version you are using. (-describe-)

2. Be careful to do the same with Stata. (-about-)

3. Be careful to flag all other do files called;
all user-written programs called; all self-written
programs called. In general, these will exist visible
to other installations of Stata only by accident.

4. Comments are useful. (* ... )

Nick
[email protected]

Neil Shephard

> Are there resources for systematic and efficient "best
> practices" in do-file colding, that beginning Stata users can
> emulate and integrate into their own work?

There are a number of ways of learning Stata...


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

Best wishes,
Michael


____________________________________

Michael McCulloch
Pine Street Clinic
124 Pine Street, San Anselmo, CA 94960-2674
tel     415.407.1357
fax     415.485.1065
email:  [email protected]
web:    www.pinest.org
        www.pinestreetfoundation.org





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