generate_neds_pts: Generate simulated 'NEDS' data for 'PCCC' and bigger wide...

generate_neds_ptsR Documentation

Generate simulated 'NEDS' data for 'PCCC' and bigger wide data testing

Description

Generate simulated 'NEDS' data for 'PCCC' and bigger wide data testing

Usage

generate_neds_pts(n = 1000L, ncol = 20L, icd10 = TRUE, verbose = FALSE)

Arguments

n

Integer number of rows of data to generate

ncol

Integer number of diagnostic code columns, default of 20 matches NEDS

icd10

Logical, default TRUE to sample ICD-10-CM codes. FALSE gives ICD-9

verbose

single logical value, defaults to FALSE in most functions.

Examples

summary(icd::comorbid_pccc_dx(icd:::generate_neds_pts()))
neds <- icd:::generate_neds_pts(n = 100, ncol = 10L, icd10 = FALSE)
stopifnot(dim(neds) == c(100L, 11L))
summary(icd::comorbid_pccc_dx(neds))
## Not run: 
# original size data for PCCC benchmarking:
set.seed(1441)
# Large NEDS simulation: neds <- icd:::generate_neds_pts(28584301L)
neds <- icd:::generate_neds_pts(2858L)
neds_comorbid <- icd::comorbid_pccc_dx(neds)

## End(Not run)

jackwasey/icd documentation built on Dec. 22, 2024, 4:47 a.m.