Dear experts,
I have a numeric identifier which is missing in observations that have no positive laboratory results..I encoded the variable and its largest value is 3999, the total sample size is just over 10000
I need to use that variable to reshape my data from long to wide, thus I need to assign random values to its missing part,
the problem is when I use the following line, I get many duplicates:
I am struggling to create a unique random integer using the following command
Any help is greatly appreciated
Omar
I have a numeric identifier which is missing in observations that have no positive laboratory results..I encoded the variable and its largest value is 3999, the total sample size is just over 10000
I need to use that variable to reshape my data from long to wide, thus I need to assign random values to its missing part,
the problem is when I use the following line, I get many duplicates:
Code:
replace identifier= floor((14000-4000+1)*runiform() + 4000) if identifier==.
Any help is greatly appreciated
Omar
Comment