Specialized on Data processing, Data management Implementation plan, Data Collection tools - electronic and paper base, Data cleaning specifications, Data extraction, Data transformation, Data load, Analytical Datasets, and Data analysis. BJ Data Tech Solutions teaches on design and developing Electronic Data Collection Tools using CSPro, and STATA commands for data manipulation. Setting up Data Management systems using modern data technologies such as Relational Databases, C#, PHP and Android.
Saturday, October 15, 2022
define a dummy with cond()
Dear All, Suppose the data set is
Code:
* Example generated by -dataex-. For more info, type help dataex
clear
input float n int rep78
1 3
2 3
3 .
4 3
5 4
6 3
7 .
8 3
9 3
10 3
11 3
12 2
13 3
14 3
15 4
16 3
17 2
18 2
19 3
20 5
end
My command is
Code:
gen d = cond(rep78>2,1,0)
However, I need `d' to be missing for the 3rd and 7th observations. I wonder the command `cond()' can do this?
No comments:
Post a Comment