Statalist


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

RE: st: gsort issue


From   Richard Williams <[email protected]>
To   [email protected], <[email protected]>
Subject   RE: st: gsort issue
Date   Thu, 05 Jul 2007 18:10:59 -0500

At 04:47 PM 7/5/2007, Steichen, Thomas J. wrote:
Isn't the simplest solution that missing should never be treated in
Stata code as a "number"?

Thus, things like sorts would need a documented definition of where
missing go but we wouldn't have to work around the "numeric" missing
so often.

For example,
  replace x = 3 if x > 2 & != .
becomes the much simpler
  replace x = 3 if x > 2

I wonder how often I've messed up analyses because I forgot to tag
on the "& != ." ?
Actually, you may have problems you don't know about, because this won't catch md codes of .a, .b, etc.! I tend to say

!missing(x)

or else

< .

There was a lengthy spirited discussion a few years back on the profound moral and philosophical issues involved in handling missing data; see this post and its several followups:

http://www.stata.com/statalist/archive/2004-01/msg00121.html


-------------------------------------------
Richard Williams, Notre Dame Dept of Sociology
OFFICE: (574)631-6668, (574)631-6463
HOME: (574)289-5227
EMAIL: [email protected]
WWW: http://www.nd.edu/~rwilliam

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