-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.Rmd
83 lines (61 loc) · 2.49 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# pathologie
> Tidy ICD-10-CM Interface
<!-- badges: start -->
![GitHub R package version](https://img.shields.io/github/r-package/v/andrewallenbruce/pathologie?style=flat-square&logo=R&label=Package&color=%23192a38)
[![CodeFactor](https://www.codefactor.io/repository/github/andrewallenbruce/pathologie/badge)](https://www.codefactor.io/repository/github/andrewallenbruce/pathologie)
[![Code size](https://img.shields.io/github/languages/code-size/andrewallenbruce/pathologie.svg)](https://github.com/andrewallenbruce/pathologie)
[![Last commit](https://img.shields.io/github/last-commit/andrewallenbruce/pathologie.svg)](https://github.com/andrewallenbruce/pathologie/commits/main)
[![Codecov test coverage](https://codecov.io/gh/andrewallenbruce/pathologie/graph/badge.svg)](https://app.codecov.io/gh/andrewallenbruce/pathologie)
[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://choosealicense.com/licenses/mit/)
<!-- badges: end -->
## :package: Installation
You can install **pathologie** from [GitHub](https://github.com/) with:
``` r
# install.packages("pak")
pak::pak("andrewallenbruce/pathologie")
```
## :beginner: Usage
```{r setup, message=FALSE, warning=FALSE}
library(pathologie)
library(dplyr)
```
```{r}
icd10cm(icd = c("I15.0")) |> glimpse()
```
## NLM ICD-10-CM API
```{r}
icd10api(icd_code = "I1")
```
## Conflict Edit Rules
```{r}
ex_data() |>
reframe(dob = date_of_birth,
dos = date_of_service,
icd_code,
age = years_floor(dob, dos)) |>
right_join(search_edits(group = "Age"),
by = join_by(icd_code)) |>
mutate(
conflict = apply_age_edits(icd_conflict_rule, age),
dob = NULL,
dos = NULL,
icd_conflict_group = NULL
)
```
------------------------------------------------------------------------------
## :balance_scale: Code of Conduct
Please note that the **`pathologie`** project is released with a [Contributor Code of Conduct](https://andrewallenbruce.github.io/pathologie/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms.
## :classical_building: Governance
This project is primarily maintained by [Andrew Bruce](https://github.com/andrewallenbruce). Other authors may occasionally assist with some of these duties.