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]

RE: st: RE: AW: RE: Evaluating a set of conditions

From   "Clyde Schechter" <>
Subject   RE: st: RE: AW: RE: Evaluating a set of conditions
Date   Thu, 24 Jun 2010 14:19:55 -0700

While I think the solutions posed by others so far will do the trick here,
they lack generality.  I have confronted this problem frequently, and I
believe what you need to do is simulate 3-valued logic.  Here is some code
that can be easily generalized.  I start with a data set containing your
variables id a b c d e.

local criteria a b c d e
foreach v of varlist `criteria' {
     tempvar `v'

Clyde Schechter, MA MD
Associate Professor of Family & Social Medicine

Please note new e-mail address:

*   For searches and help try:

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