simPop | R Documentation |
Simulate population with birthdate and gender
simPop(n, min.age = 20, max.age = 90, sex = 0.5, mortality = 0.05)
n |
Number of subjects |
min.age |
minimal age |
max.age |
maximal age |
sex |
gender distribution: value between 0 and 1 |
mortality |
risk of death: value between 0 and 1 |
Sample data for illustration, i.e., vignettes and example sections of the package.
data.table with columns: pnr, sex, birthdate, status, doddate where doddate is the date of death for subjects with status = 1 and the current date for subjects with status = 0.
Thomas A. Gerds <tag@biostat.ku.dk>
simPrescriptionData, simAdmissionData
set.seed(7)
simPop(7)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.