Description Usage Arguments Examples
This function allows you to find a diagnosis based on ICD-codes. Creates a new column based on the ICD-codes.
1 2 3 4 5 6 7 8 9 | identify_icd(
.data,
icd,
new_variable,
primary = TRUE,
secondary = TRUE,
simple = FALSE,
patient_inclusion = FALSE
)
|
.data |
A tibble with data in QTF-format. |
icd |
A character vector (or scalar) with ICD-codes that should be identified in the data. |
new_variable |
A character string with the column name for the new variable. |
primary |
Search primary diagnoses. Defaults to TRUE. |
secondary |
Search secondary diagnoses. Defaults to TRUE. |
simple |
Only the new variable column will be returned. Support function. Defaults to FALSE. |
patient_inclusion |
Return a vector with unique patient id:s that can be used to filter data at a later stage. Defaults to FALSE. |
1 2 | data(data_icd)
data_icd %>% combine_sdia() %>% identify_icd("L405", "psa")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.