⇤ ← Revision 1 as of 2023-06-07 18:59:15
Size: 420
Comment:
|
Size: 488
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 2: | Line 2: |
Stata supports the following logical structures for programming. |
Stata Logic
Stata supports the following logical structures for programming.
Contents
Operators
Conditional Processing
By
The by command prefix causes a command to be repeated within groups.
A common usecase of the by structure is for identifying duplciate cases.
sort foo bar baz by foo bar baz: generate byte duplicate = cond(_N==1, 0, _n)