-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathREADME.Rmd
127 lines (90 loc) · 4.01 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
# healthequal - Calculating summary measures of inequality <img src="man/figures/logo.png" align="right" height="140" alt="healthequal website">
<!-- badges: start -->
[](https://www.repostatus.org/#active)
[](https://choosealicense.com/licenses/agpl-3.0/)
[](https://github.com/WHOequity/healthequal/actions/workflows/R-CMD-check.yaml)
[](https://CRAN.R-project.org/package=healthequal)
<!-- badges: end -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%",
message = FALSE
)
library(healthequal)
```
The `healthequal` package provides computational tools for calculating 21 summary measures of health inequality.
# Installation
You can install the released version of healthequal from [CRAN](https://CRAN.R-project.org) with:
``` r
install.packages("healthequal")
```
The development version can be installed from [GitHub](https://github.com/) with:
``` r
# install.packages("remotes")
remotes::install_github("WHOequity/healthequal")
```
## Measures of health inequality included in `healthequal`:
The following summary measures of health inequality are included in the `healthequal` package:
### Simple measures
- Difference (`d`)
- Ratio (`r`)
### Disproportionality measures (ordered dimensions)
- Absolute concentration index (`aci`)
- Relative concentration index (`rci`)
### Regression-based measures (ordered dimensions)
- Slope index of inequality (`sii`)
- Relative index of inequality (`rii`)
### Variance measures (non-ordered dimensions)
- Between-group variance (`bgv`)
- Between-group standard deviation (`bgsd`)
- Coefficient of variation (`covar`)
### Mean difference measures (non-ordered dimensions)
- Mean difference from mean - unweighted and weighted (`mdmu` and `mdmw`)
- Mean difference from best-performing subgroup - unweighted and weighted (`mdbu` and `mdbw`)
- Mean difference from reference subgroup - unweighted and weighted (`mdru` and `mdrw`)
- Index of disparity - unweighted and weighted (`idisu` and `idisw`)
### Disproportionality measures (non-ordered dimensions)
- Theil index (`ti`)
- Mean log deviation (`mld`)
### Impact measures
- Population attributable risk (`parisk`)
- Population attributable fraction (`paf`)
# Package data
The `healthequal` package comes with sample data for users to be able to test the package functions. The `OrderedSample` and `NonorderedSample` data contain data disaggregated by economic status and subnational region, respectively, for a single indicator.
### Ordered and Nonordered data
``` r
data(OrderedSample)
head(OrderedSample)
```
``` r
data(NonorderedSample)
head(NonorderedSample)
```
### Disagregated data
The `OrderedSampleMultipleind` and `OrderedSampleMultipleind` data contain disaggregated data by economic status and subnational region, respectively, for two indicators.
``` r
data(OrderedSampleMultipleind)
head(OrderedSampleMultipleind)
```
``` r
data(NonorderedSampleMultipleind)
head(NonorderedSampleMultipleind)
```
### More info on the datasets
For information about the datasets, type the following commands, which will display the corresponding dataset help file:
``` r
?healthequal::OrderedSample
?healthequal::NonorderedSample
?healthequal::OrderedSampleMultipleind
?healthequal::NonorderedSampleMultipleind
?healthequal::IndividualSample
```
# References:
Schlotheuber, A, Hosseinpoor, AR. Summary measures of health inequality: A review of existing measures and their application. Int J Environ Res Public Health. 2022;19(6):3697. [doi:10.3390/ijerph19063697](https://doi.org/10.3390/ijerph19063697)