Skip to content

Commit

Permalink
tidy up vignettes and docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ernestguevarra committed Feb 22, 2024
1 parent 7ee4b72 commit 3f01b14
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 21 deletions.
3 changes: 1 addition & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ Language: en-GB
LazyData: true
RoxygenNote: 7.2.3
Roxygen: list(markdown = TRUE)
URL: https://nutriverse.io/micronutr/,
https://github.com/nutriverse/micronutr
URL: https://nutriverse.io/micronutr/,https://github.com/nutriverse/micronutr
BugReports: https://github.com/nutriverse/micronutr/issues
Config/testthat/edition: 3
VignetteBuilder: knitr
10 changes: 6 additions & 4 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
# micronutr 0.0.0.9000

This is a pre-release of `micronutr` package.

# micronutr 0.0.0.9001

This is an updated pre-release of the micronutr package.

The update corrects missing links to community guidelines on code of conduct and contributing to the project in the package website and README.

This update also allows for an initial Zenodo DOI to be allocated to the release in preparation for eventual CRAN publication.


# micronutr 0.0.0.9000

This is a pre-release of `micronutr` package.

3 changes: 1 addition & 2 deletions man/micronutr.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion pkgdown/_pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ navbar:
type: light
structure:
left: [home, reference, articles, news]
right: [linkedin, github]
right: [mastodon, linkedin, github]

components:
articles:
Expand All @@ -27,6 +27,9 @@ navbar:
href: articles/iron-deficiency.html
- text: "Detecting iodine deficiency"
href: articles/iodine-deficiency.html
mastodon:
icon: "fab fa-mastodon fa-lg"
href: https://fosstodon.org/@katilingban
linkedin:
icon: "fab fa-linkedin fa-lg"
href: https://www.linkedin.com/company/katilingban
Expand Down
12 changes: 6 additions & 6 deletions vignettes/inflammation.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ The classification of inflammation status based on either CRP or AGP only is sho

**Acute-phase Protein** | **Cut-off Points**
:--- | :---
CRP | > 5 µ/L
CRP | > 5 microgram/L
AGP | > 1 g/L

The function `detect_inflammation_crp()` classifies *c-reactive protein* levels based on the cut-off point shown above to detect inflammation. For example, if CRP is at 2 µg/L,
The function `detect_inflammation_crp()` classifies *c-reactive protein* levels based on the cut-off point shown above to detect inflammation. For example, if CRP is at 2 microgram/L,

```{r micronutr5, echo = TRUE}
detect_inflammation_crp(crp = 2)
Expand Down Expand Up @@ -69,11 +69,11 @@ The detailed classification of inflammation status based on the combination of C

**Inflammation Status** | **Cut-off Points**
:--- | :--- |
Incubation | CRP > 5 µg/L and AGP <= 1 g/L
Early convalescence | CRP > 5 µg/L and AGP > 1 g/L
Late convalescence | CRP <= 5 µg/L and AGP > 1 g/L
Incubation | CRP > 5 microgram/L and AGP <= 1 g/L
Early convalescence | CRP > 5 microgram/L and AGP > 1 g/L
Late convalescence | CRP <= 5 microgram/L and AGP > 1 g/L

The function `detect_inflammation()` accepts values for both CRP and AGP to classify inflammation status. For example, an individual with CRP of 2 µg/L and AGP of 1.5 g/L,
The function `detect_inflammation()` accepts values for both CRP and AGP to classify inflammation status. For example, an individual with CRP of 2 microgram/L and AGP of 1.5 g/L,

```{r micronutr9, echo = TRUE}
detect_inflammation(crp = 2, agp = 1.5)
Expand Down
12 changes: 6 additions & 6 deletions vignettes/iron-deficiency.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ It is recommended that serum ferritin be adjusted accordingly depending on the i

The first approach is by increasing the serum ferritin cut-off for detecting iron deficiency. The recommendation is that if an individual has been assessed to be in an inflammatory or infectious state, serum ferritin level of less than 30 µg/L will classify this individual as being iron deficient regardless of age group.

The function `detect_iron_deficiency_qualitative()` facilitates this classification. For example, a 2 year old with a serum ferritin of 15.6 µg/L who has been assessed to have an active infection, we can assess iron deficiency status as follows:
The function `detect_iron_deficiency_qualitative()` facilitates this classification. For example, a 2 year old with a serum ferritin of 15.6 microgram/L who has been assessed to have an active infection, we can assess iron deficiency status as follows:

```{r ferritin5, echo = TRUE}
detect_iron_deficiency_qualitative(ferritin = 15.6, inflammation = TRUE)
Expand Down Expand Up @@ -101,9 +101,9 @@ The second approach for correcting serum ferritin is by using an arithmetic corr

**Inflammation Stages** | **CRP and AGP Cut-off Points** | **Correction Factor**
:--- | :--- | :---
Incubation | CRP > 5 µg/L and AGP <= 1 g/L | 0.77
Early convalescence | CRP > 5 µg/L and AGP > 1 g/L | 0.53
Late convalescence | CRP <= 5 µg/L and AGP > 1 g/L | 0.75
Incubation | CRP > 5 microgram/L and AGP <= 1 g/L | 0.77
Early convalescence | CRP > 5 microgram/L and AGP > 1 g/L | 0.53
Late convalescence | CRP <= 5 microgram/L and AGP > 1 g/L | 0.75

CRP and AGP are biomarkers for inflammation and the values for these acute-phase proteins combined indicate the different stages of inflammation that an individual is at. Based on the inflammation stage, a corresponding correction factor can be applied to serum ferritin to adjust its value.

Expand All @@ -113,13 +113,13 @@ The function `correct_ferritin()` allows for this serum ferritin adjustment to b
correct_ferritin(crp = 2, agp = 2, ferritin = 11.3)
```

This gives us a corrected serum ferritin value of 5.99 µg/L.
This gives us a corrected serum ferritin value of 5.99 microgram/L.

In some settings, values for both CRP and AGP may not be available. Usually, only CRP or AGP are available or are measured. In these settings, we can use functions to correct ferritin using only one of these acute-phase proteins based on the following correction factors:

**Acute-phase Protein** | **Cut-off Points** | **Correction Factor**
:--- | :--- | :---
CRP | > 5 µg/L | 0.65
CRP | > 5 microgram/L | 0.65
AGP | > g/L | 0.72

For example, for a person with serum ferritin of 11.3 µg/L and a CRP of 2, we use the `correct_ferritin()` function as follows:
Expand Down

0 comments on commit 3f01b14

Please sign in to comment.