Code:
clear set obs 100 gen foo=rnormal(5,2)
Code:
gen foo2 = runiform() replace foo if foo2 < 0.2
Also, how can I randomly replace with . only a certain number of observations?
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.
clear set obs 100 gen foo=rnormal(5,2)
gen foo2 = runiform() replace foo if foo2 < 0.2
0 Response to Generate data with missing values and specific mean / standard deviation
Post a Comment