https://github.com/nutriverse/anthrocheckr
An Implementation of Anthropometric Measurement Standardisation Tests
https://github.com/nutriverse/anthrocheckr
anthropometry standardisation
Last synced: 6 months ago
JSON representation
An Implementation of Anthropometric Measurement Standardisation Tests
- Host: GitHub
- URL: https://github.com/nutriverse/anthrocheckr
- Owner: nutriverse
- License: gpl-3.0
- Created: 2018-12-23T19:07:51.000Z (over 7 years ago)
- Default Branch: main
- Last Pushed: 2024-12-11T12:01:22.000Z (over 1 year ago)
- Last Synced: 2024-12-11T12:32:16.508Z (over 1 year ago)
- Topics: anthropometry, standardisation
- Language: R
- Homepage: https://nutriverse.io/anthrocheckr/
- Size: 8.17 MB
- Stars: 4
- Watchers: 4
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.Rmd
- Changelog: NEWS.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE.md
- Code of conduct: .github/CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
---
output: github_document
---
```{r setup, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# anthrocheckr: An Implementation of Anthropometric Measurement Standardisation Tests 
[](https://www.repostatus.org/#active)
[](https://www.tidyverse.org/lifecycle/#maturing)
[](https://github.com/nutriverse/anthrocheckr/actions/workflows/R-CMD-check.yaml)
[](https://github.com/nutriverse/anthrocheckr/actions)
[](https://app.codecov.io/gh/nutriverse/anthrocheckr?branch=main)
[](https://www.codefactor.io/repository/github/nutriverse/anthrocheckr)
[](https://zenodo.org/badge/latestdoi/162917178)
Ensuring the precision and accuracy of measurements is critical when collecting anthropometric data. Anthropometrists are usually tested for precision and accuracy of measurement through standardisation tests performed prior to anthropometric data collection. This package provides functions to calculate inter- and intra-observer technical error of measurement (TEM) to assess precision of measurements.
## What does the package do?
`{anthrocheckr}` provides functions for:
1. Calculating standard summaries for intra-observer or inter-observer measurements;
2. Calculating intra-observer or inter-observer technical error of measurement (TEM) for multiple subjects and for multiple measurers/observers;
3. Calculating multiple measurers/observers relative technical error of measurement (relative TEM);
4. Calculating intra-observer total technical error of measurement (total TEM);
5. Calculating coefficient of reliability; and,
6. Calculating bias in measurements/observation against a gold standard.
## Installation
`{anthrocheckr}` is not yet on [CRAN](https://cran.r-project.org) but can be installed from the [nutriverse R Universe](https://nutriverse.r-universe.dev) as follows:
```{r install-r-universe, eval = FALSE}
install.packages(
"anthrocheckr",
repos = c('https://nutriverse.r-universe.dev', 'https://cloud.r-project.org')
)
```
## Usage
### Calculate intra-observer and/or inter-observer summaries
The *mean*, *standard deviation*, and *maximum difference in measurements* are the requisite summary measures for various anthropometric measurement standardisations tests. These can be calculated as follows:
```{r mean-summary}
## Intra-observer mean for weight ----
weight_df <- subset(smartStdLong, subset = measure_type == "weight")
calculate_mean(weight_df$measure_value, index = weight_df$observer)
```
```{r sd-summary}
## Intra-observer sd for weight ----
calculate_sd(weight_df$measure_value, index = weight_df$observer)
```
```{r max-diff-summary}
## Intra-observer max difference for weight ----
weight_df_wide <- tidyr::pivot_wider(
weight_df,
names_from = c(measure_type, measure_round),
values_from = measure_value, names_sep = "_"
)
calculate_max(
abs(weight_df_wide$weight_1 - weight_df_wide$weight_2),
index = weight_df_wide$observer
)
```
### Calculate intra-observer and inter-observer technical error of measurement (TEM)
```{r calculate-inter-tem, eval = FALSE}
## Inter-observer max difference for weight ----
weight_df_wide <- tidyr::pivot_wider(
weight_df,
names_from = c(measure_type, measure_round),
values_from = measure_value, names_sep = "_"
)
inter_tem <- calculate_tem(
abs(weight_df_wide$weight_1 - weight_df_wide$weight_2),
n = nrow(weight_df_wide)
)
```
which gives
```{r calculate-inter-tem-show, echo = FALSE}
calculate_tem(
abs(weight_df_wide$weight_1 - weight_df_wide$weight_2),
n = nrow(weight_df_wide)
)
```
```{r calculate-intra-tem, eval = FALSE}
## Intra-observer max difference for weight ----
weight_df_wide <- tidyr::pivot_wider(
weight_df,
names_from = c(measure_type, measure_round),
values_from = measure_value, names_sep = "_"
)
intra_tem <- calculate_tem_cohort(
df = weight_df_wide, m1 = "weight_1", m2 = "weight_2",
index = "observer", n = nrow(weight_df_wide)
)
```
which gives
```{r calculate-intra-tem-show, echo = FALSE}
calculate_tem_cohort(
df = weight_df_wide, m1 = "weight_1", m2 = "weight_2",
index = "observer", n = nrow(weight_df_wide)
)
```
### Calculating relative technical error of measurement
```{r calculate-relative-tem}
mean_weight <- calculate_mean(
weight_df$measure_value, index = weight_df$observer
)
calculate_relative_tem(intra_tem$tem, mean_weight$mean)
```
## Citation
If you use the `{anthrocheckr}` package in your work, please cite using the suggested citation provided by a call to the `citation()` function as follows:
```{r citation}
citation("anthrocheckr")
```
## Community guidelines
Feedback, bug reports and feature requests are welcome; file issues or seek support [here](https://github.com/nutriverse/anthrocheckr/issues). If you would like to contribute to the package, please see our [contributing guidelines](https://nutriverse.io/anthrocheckr/CONTRIBUTING.html).
Please note that the `{anthrocheckr}` project is released with a [Contributor Code of Conduct](https://nutriverse.io/anthrocheckr/CODE_OF_CONDUCT.html). By contributing to this project, you agree to abide by its terms.