Creating Random Abstracting Samples
Creating Random Abstracting Samples
Generating Random Samples from CPDMS Database
This procedure is used to generate a random sample of cases from the KCR central registry.
- Make sure central is not being merged and if not, get copy of central (/kcr/bin/kcrimport.ram - copies central:/kcr/central to /kcr/ramdisk)
- Create login for user random (study groups already exist on mordor)
- Create working directory for random sample (if desired) under /kcr/audits/
- Create Study Group: Select All Cases where DiagDate 07/01/2011 thru 12/31/2011 and DiagState = KY and hosp in ... etc, etc.
- In CPDMS, ASCIIOut using random.fmt. (Generates random.out and random.rl)
- Sort records by random number: cat random.out | sort > random.srt (make sort)
- Select subset group of records and format and sort output
* Edit randfmt.php to define file names and sample size
* randfmt - opens random.srt, selects subset, formats output into random.txt and control list in random.ctl; output data is sorted by field 2 (hospid) - Copy random.ctl, random.rpt, random.txt to J:\Emily\Random Case Samples\MonYYYY
Last Updated 07/24/2013
, multiple selections available,