Skip to contents

This dataset represents a synthetic nonprobability sample generated via Poisson sampling from a finite population constructed from the National Health and Nutrition Examination Survey (NHANES) cycles 1999–2010. It is intended to illustrate the pseudo-weighting methods implemented in the nonprobsampling package.

Usage

data(sc)

Format

A data frame with 2404 observations and 8 variables:

psa_level

Outcome variable: serum prostate-specific antigen level (numeric)

BMI

Body mass index category (factor with 4 levels: "Normal", "Overweight", "Obese", "Morbidly Obese")

race

Race category (factor with 4 levels: 1 = White, 2 = Black, 3 = Hispanic, 4 = Other)

agecat

Age category (factor with 4 levels: 1 = 55–59, 2 = 60–64, 3 = 65–69, 4 = 70+)

education

Education level (factor with 5 levels: 1 = Less Than 8 Years, 2 = 8–11 Years, 3 = 12 Years Or Completed High School, 4 = College Graduate, 5 = Postgraduate)

pros_enlarged

Prostate enlargement indicator (factor with 2 levels: 0 = No, 1 = Yes)

comorbidity

General comorbidity indicator (factor with 2 levels: 0 = No, 1 = Yes)

diabetes

Diabetes diagnosis indicator (factor with 2 levels: 0 = No, 1 = Yes)

Source

Synthetic data generated by the package authors. The underlying finite population was constructed from the National Health and Nutrition Examination Survey (NHANES), 1999–2010 cycles, conducted by the U.S. National Center for Health Statistics (NCHS).

Details

The dataset has 2,404 complete-case observations, with psa_level serving as the outcome variable. Auxiliary variables shared with the probability reference surveys sp1 and sp2 are used to construct pseudo-weights aimed at correcting for participation bias.

Examples

data(sc)
str(sc)
#> 'data.frame':	2404 obs. of  8 variables:
#>  $ psa_level    : num  0.3 1 1 1.2 0.3 1 0.3 1 1 0.3 ...
#>  $ BMI          : Factor w/ 4 levels "Morbidly Obese",..: 1 1 4 3 2 1 2 4 4 1 ...
#>  $ race         : Factor w/ 4 levels "1","2","3","4": 1 1 1 1 1 1 1 1 1 1 ...
#>  $ agecat       : Factor w/ 4 levels "1","2","3","4": 1 2 2 4 2 3 2 2 2 1 ...
#>  $ education    : Factor w/ 5 levels "1","2","3","4",..: 4 3 4 4 1 3 1 4 4 4 ...
#>  $ pros_enlarged: Factor w/ 2 levels "0","1": 1 1 1 1 1 1 1 1 1 1 ...
#>  $ comorbidity  : Factor w/ 2 levels "0","1": 2 2 1 2 2 2 2 1 1 2 ...
#>  $ diabetes     : Factor w/ 2 levels "0","1": 2 2 1 1 1 2 1 1 1 2 ...
summary(sc)
#>    psa_level                  BMI       race     agecat  education
#>  Min.   : 0.070   Morbidly Obese: 195   1:1694   1:853   1:276    
#>  1st Qu.: 0.600   Normal        : 618   2: 276   2:678   2:294    
#>  Median : 1.000   Obese         : 573   3: 299   3:523   3:503    
#>  Mean   : 1.536   Overweight    :1018   4: 135   4:350   4:558    
#>  3rd Qu.: 1.860                                          5:773    
#>  Max.   :34.960                                                   
#>  pros_enlarged comorbidity diabetes
#>  0:1838        0: 981      0:1982  
#>  1: 566        1:1423      1: 422  
#>                                    
#>                                    
#>                                    
#>