1
0
mirror of https://github.com/msberends/AMR.git synced 2024-12-25 18:46:11 +01:00

direct warning if failing as.mo

This commit is contained in:
dr. M.S. (Matthijs) Berends 2019-01-12 16:45:20 +01:00
parent 5aad26035c
commit 3661df7365
3 changed files with 8 additions and 8 deletions

View File

@ -6,17 +6,17 @@
* New website: https://msberends.gitlab.io/AMR (built with the great [`pkgdown`](https://pkgdown.r-lib.org/))
* Contains the complete manual of this package and all of its functions with an explanation of their parameters
* Contains a comprehensive tutorial about how to conduct antimicrobial resistance analysis
* Support for [`dplyr`](https://dplyr.tidyverse.org) version 0.8.0
* Function `guess_ab_col` to find an antibiotic column in a table
* Support for the upcoming [`dplyr`](https://dplyr.tidyverse.org) version 0.8.0
* Function `guess_ab_col()` to find an antibiotic column in a table
* Function `mo_failures()` to review values that could not be coerced to a valid MO code, using `as.mo()`. This latter function will now only show a maximum of 25 uncoerced values.
* Function `mo_renamed()` to get a list of all returned values from `as.mo()` that have had taxonomic renaming
* Function `age()` to calculate the (patients) age in years
* Function `age_groups()` to split ages into custom or predefined groups (like children or elderly). This allows for easier demographic antimicrobial resistance analysis per age group.
* Functions `filter_first_isolate()` and `filter_first_weighted_isolate()` to shorten and fasten filtering on data sets with antimicrobial results, e.g.:
```r
septic_patients %>% filter_first_isolate()
septic_patients %>% filter_first_isolate(...)
# or
filter_first_isolate(septic_patients)
filter_first_isolate(septic_patients, ...)
```
is equal to:
```r

2
R/mo.R
View File

@ -711,7 +711,7 @@ exec_as.mo <- function(x, Becker = FALSE, Lancefield = FALSE,
paste('"', unique(failures), '"', sep = "", collapse = ', '),
". See mo_failures() to review them.")),
call. = FALSE,
immediate. = FALSE)
immediate. = TRUE) # thus will always be shown, even if >= warnings
}
}

View File

@ -232,13 +232,13 @@
<li>New website: <a href="https://msberends.gitlab.io/AMR" class="uri">https://msberends.gitlab.io/AMR</a> (built with the great <a href="https://pkgdown.r-lib.org/"><code>pkgdown</code></a>)</li>
<li>Contains the complete manual of this package and all of its functions with an explanation of their parameters</li>
<li>Contains a comprehensive tutorial about how to conduct antimicrobial resistance analysis</li>
<li>Support for <a href="https://dplyr.tidyverse.org"><code>dplyr</code></a> version 0.8.0</li>
<li>Function <code>guess_ab_col</code> to find an antibiotic column in a table</li>
<li>Support for the upcoming <a href="https://dplyr.tidyverse.org"><code>dplyr</code></a> version 0.8.0</li>
<li>Function <code><a href="../reference/guess_ab_col.html">guess_ab_col()</a></code> to find an antibiotic column in a table</li>
<li>Function <code><a href="../reference/mo_failures.html">mo_failures()</a></code> to review values that could not be coerced to a valid MO code, using <code><a href="../reference/as.mo.html">as.mo()</a></code>. This latter function will now only show a maximum of 25 uncoerced values.</li>
<li>Function <code><a href="../reference/mo_renamed.html">mo_renamed()</a></code> to get a list of all returned values from <code><a href="../reference/as.mo.html">as.mo()</a></code> that have had taxonomic renaming</li>
<li>Function <code><a href="../reference/age.html">age()</a></code> to calculate the (patients) age in years</li>
<li>Function <code><a href="../reference/age_groups.html">age_groups()</a></code> to split ages into custom or predefined groups (like children or elderly). This allows for easier demographic antimicrobial resistance analysis per age group.</li>
<li>Functions <code><a href="../reference/first_isolate.html">filter_first_isolate()</a></code> and <code><a href="../reference/first_isolate.html">filter_first_weighted_isolate()</a></code> to shorten and fasten filtering on data sets with antimicrobial results, e.g.: <code>r septic_patients %&gt;% filter_first_isolate() # or filter_first_isolate(septic_patients)</code> is equal to: <code>r septic_patients %&gt;% mutate(only_firsts = first_isolate(septic_patients, ...)) %&gt;% filter(only_firsts == TRUE) %&gt;% select(-only_firsts)</code>
<li>Functions <code><a href="../reference/first_isolate.html">filter_first_isolate()</a></code> and <code><a href="../reference/first_isolate.html">filter_first_weighted_isolate()</a></code> to shorten and fasten filtering on data sets with antimicrobial results, e.g.: <code>r septic_patients %&gt;% filter_first_isolate(...) # or filter_first_isolate(septic_patients, ...)</code> is equal to: <code>r septic_patients %&gt;% mutate(only_firsts = first_isolate(septic_patients, ...)) %&gt;% filter(only_firsts == TRUE) %&gt;% select(-only_firsts)</code>
</li>
<li>New vignettes about how to conduct AMR analysis, predict antimicrobial resistance, use the <em>G</em>-test and more. These are also available (and even easier readable) on our website: <a href="https://msberends.gitlab.io/AMR" class="uri">https://msberends.gitlab.io/AMR</a>.</li>
</ul>