Last updated: 2022-03-16
Checks: 5 2
Knit directory: codemapper/
This reproducible R Markdown analysis was created with workflowr (version 1.6.2). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.
The R Markdown file has unstaged changes. To know which version of the R Markdown file created these results, you’ll want to first commit it to the Git repo. If you’re still working on the analysis, you can ignore this warning. When you’re finished, you can run wflow_publish to commit the R Markdown file and build the HTML.
The global environment had objects present when the code in the R Markdown file was run. These objects can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment. Use wflow_publish or wflow_build to ensure that the code is always run in an empty environment.
The following objects were defined in the global environment when these results were created:
| Name | Class | Size |
|---|---|---|
| install_codemapper | function | 1.2 Kb |
The command set.seed(20210923) was run prior to running the code in the R Markdown file. Setting a seed ensures that any results that rely on randomness, e.g. subsampling or permutations, are reproducible.
Great job! Recording the operating system, R version, and package versions is critical for reproducibility.
Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.
Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.
Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.
The results in this page were generated with repository version 193f2cb. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.
Note that you need to be careful to ensure that all relevant files for the analysis have been committed to Git prior to generating the results (you can use wflow_publish or wflow_git_commit). workflowr only checks the R Markdown file, but you know if there are other scripts or data files that it depends on. Below is the status of the Git repository when the results were generated:
Ignored files:
Ignored: .Renviron
Ignored: .Rhistory
Ignored: .Rproj.user/
Ignored: _targets/
Ignored: all_lkps_maps.db
Ignored: all_lkps_maps.db.gz
Ignored: renv/library/
Ignored: renv/staging/
Ignored: tar_make.R
Untracked files:
Untracked: analysis/read3_read2_mapping.Rmd
Unstaged changes:
Modified: R/clinical_codes.R
Modified: _targets.R
Modified: analysis/index.Rmd
Modified: analysis/read2_read3_mapping.Rmd
Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.
These are the previous versions of the repository in which changes were made to the R Markdown (analysis/index.Rmd) and HTML (public/index.html) files. If you’ve configured a remote Git repository (see ?wflow_git_remote), click on the hyperlinks in the table below to view the files as they were in that past version.
| File | Version | Author | Date | Message |
|---|---|---|---|---|
| Rmd | 193f2cb | rmgpanw | 2022-03-16 | add notes re icd9-10 mapping, and reformatting function for ths mapping table |
| html | 193f2cb | rmgpanw | 2022-03-16 | add notes re icd9-10 mapping, and reformatting function for ths mapping table |
| Rmd | 84beb4f | rmgpanw | 2022-03-16 | update notes on read to icd10 mapping |
| html | 84beb4f | rmgpanw | 2022-03-16 | update notes on read to icd10 mapping |
| Rmd | e5c5381 | rmgpanw | 2022-03-10 | update mainly icd10-related codes. |
| Rmd | a64a35e | rmgpanw | 2022-03-10 | change arg quiet = TRUE to unrecognised_codes = “error”. Also updated tests (passing) |
| Rmd | dfbc621 | Chuin Ying Ung | 2022-02-22 | add mapping notes |
| html | dfbc621 | Chuin Ying Ung | 2022-02-22 | add mapping notes |
| html | d777258 | Chuin Ying Ung | 2022-02-22 | merge with dev_cy branch |
| Rmd | 5b80a79 | Chuin Ying Ung | 2022-02-22 | update notes |
| html | 5b80a79 | Chuin Ying Ung | 2022-02-22 | update notes |
| html | 81047b4 | rmgpanw | 2022-02-17 | setup for gitlab CI with pkgdown site and test coverage; start adding read3 to snomed mapping |
| html | 5c2a3e3 | Chuin Ying Ung | 2022-02-17 | update _targets.R (housekeeping) and phecode.Rmd |
| Rmd | 919be0d | rmgpanw | 2021-10-07 | renamed functions and made shiny app for selecting codes |
| html | 919be0d | rmgpanw | 2021-10-07 | renamed functions and made shiny app for selecting codes |
| Rmd | 3fe5ae7 | rmgpanw | 2021-09-23 | initial commit |
Notes on adapting raw lookup and mapping tables for codemapper (see also pkgdown site)
Specify the location of required raw data files in a .Renviron file in the root directory of this project:
library(magrittr)
targets::tar_read(RENVIRON) %>%
readLines() %>%
purrr::map_chr( ~ stringr::str_replace(
string = .x,
pattern = "=.*$",
replacement = "="
)) %>%
stringr::str_c(sep = "",
collapse = "\n") %>%
cat()
# Files loacted outside this repo --------
## TRUD
CTV3SCTMAP2=
## PheWAS
PHECODE_1_2_LKP=
PHECODE_1_2_ICD10_MAP=
PHECODE_1_2_ICD9_MAP=
# gitlab authorisation token --------
GITLAB_PAT=
sessionInfo()
R version 4.1.0 (2021-05-18)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Big Sur 10.16
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRblas.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRlapack.dylib
locale:
[1] en_GB.UTF-8/en_GB.UTF-8/en_GB.UTF-8/C/en_GB.UTF-8/en_GB.UTF-8
attached base packages:
[1] stats graphics grDevices datasets utils methods base
other attached packages:
[1] magrittr_2.0.1 workflowr_1.6.2
loaded via a namespace (and not attached):
[1] Rcpp_1.0.7 pillar_1.6.3 compiler_4.1.0 bslib_0.3.1
[5] later_1.3.0 jquerylib_0.1.4 git2r_0.28.0 highr_0.9
[9] tools_4.1.0 targets_0.8.0 digest_0.6.28 jsonlite_1.7.2
[13] evaluate_0.14 lifecycle_1.0.1 tibble_3.1.4 pkgconfig_2.0.3
[17] rlang_0.4.11 igraph_1.2.6 rstudioapi_0.13 cli_3.0.1
[21] yaml_2.2.1 xfun_0.24 fastmap_1.1.0 withr_2.4.3
[25] stringr_1.4.0 knitr_1.34 fs_1.5.0 vctrs_0.3.8
[29] sass_0.4.0 tidyselect_1.1.1 rprojroot_2.0.2 data.table_1.14.2
[33] glue_1.4.2 R6_2.5.1 processx_3.5.2 fansi_0.5.0
[37] rmarkdown_2.11 callr_3.7.0 purrr_0.3.4 whisker_0.4
[41] codetools_0.2-18 ps_1.6.0 promises_1.2.0.1 ellipsis_0.3.2
[45] htmltools_0.5.2 renv_0.13.2 httpuv_1.6.3 utf8_1.2.2
[49] stringi_1.7.4 crayon_1.4.1