mirror of https://github.com/msberends/AMR.git
freq fix
This commit is contained in:
parent
5eda991c47
commit
c3ae6b7699
|
@ -69,6 +69,7 @@ R-release:
|
||||||
- '*.Rcheck/*'
|
- '*.Rcheck/*'
|
||||||
expire_in: '1 month'
|
expire_in: '1 month'
|
||||||
cache:
|
cache:
|
||||||
|
when: always
|
||||||
key: "r350"
|
key: "r350"
|
||||||
paths:
|
paths:
|
||||||
- installed_deps/
|
- installed_deps/
|
||||||
|
@ -99,6 +100,7 @@ R-devel:
|
||||||
- '*.Rcheck/*'
|
- '*.Rcheck/*'
|
||||||
expire_in: '1 month'
|
expire_in: '1 month'
|
||||||
cache:
|
cache:
|
||||||
|
when: always
|
||||||
key: "r360"
|
key: "r360"
|
||||||
paths:
|
paths:
|
||||||
- installed_deps/
|
- installed_deps/
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
Package: AMR
|
Package: AMR
|
||||||
Version: 0.6.1.9003
|
Version: 0.6.1.9003
|
||||||
Date: 2019-05-16
|
Date: 2019-05-17
|
||||||
Title: Antimicrobial Resistance Analysis
|
Title: Antimicrobial Resistance Analysis
|
||||||
Authors@R: c(
|
Authors@R: c(
|
||||||
person(
|
person(
|
||||||
|
|
10
R/freq.R
10
R/freq.R
|
@ -585,10 +585,12 @@ format_header <- function(x, markdown = FALSE, decimal.mark = ".", big.mark = ",
|
||||||
# FORMATTING
|
# FORMATTING
|
||||||
# rsi
|
# rsi
|
||||||
if (has_length == TRUE & any(x_class == "rsi")) {
|
if (has_length == TRUE & any(x_class == "rsi")) {
|
||||||
ab <- tryCatch(as.ab(attributes(x)$opt$vars), error = function(e) NA)
|
if (!is.null(attributes(x)$opt$vars)) {
|
||||||
if (!is.na(ab) & isTRUE(length(ab) > 0)) {
|
ab <- tryCatch(as.ab(attributes(x)$opt$vars), error = function(e) NA)
|
||||||
header$drug <- paste0(ab_name(ab[1L]), " (", ab[1L], ", ", ab_atc(ab[1L]), ")")
|
if (!is.na(ab) & isTRUE(length(ab) > 0)) {
|
||||||
header$group <- ab_group(ab[1L])
|
header$drug <- paste0(ab_name(ab[1L]), " (", ab[1L], ", ", ab_atc(ab[1L]), ")")
|
||||||
|
header$group <- ab_group(ab[1L])
|
||||||
|
}
|
||||||
}
|
}
|
||||||
header$`%SI` <- percent(header$count_SI / (header$count_SI + header$count_R),
|
header$`%SI` <- percent(header$count_SI / (header$count_SI + header$count_R),
|
||||||
force_zero = TRUE, round = digits, decimal.mark = decimal.mark)
|
force_zero = TRUE, round = digits, decimal.mark = decimal.mark)
|
||||||
|
|
|
@ -259,6 +259,8 @@
|
||||||
|
|
||||||
<span class='fu'>ab_ddd</span>(<span class='no'>x</span>, <span class='kw'>administration</span> <span class='kw'>=</span> <span class='st'>"oral"</span>, <span class='kw'>units</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>, <span class='no'>...</span>)
|
<span class='fu'>ab_ddd</span>(<span class='no'>x</span>, <span class='kw'>administration</span> <span class='kw'>=</span> <span class='st'>"oral"</span>, <span class='kw'>units</span> <span class='kw'>=</span> <span class='fl'>FALSE</span>, <span class='no'>...</span>)
|
||||||
|
|
||||||
|
<span class='fu'>ab_info</span>(<span class='no'>x</span>, <span class='kw'>language</span> <span class='kw'>=</span> <span class='fu'><a href='translate.html'>get_locale</a></span>(), <span class='no'>...</span>)
|
||||||
|
|
||||||
<span class='fu'>ab_property</span>(<span class='no'>x</span>, <span class='kw'>property</span> <span class='kw'>=</span> <span class='st'>"name"</span>, <span class='kw'>language</span> <span class='kw'>=</span> <span class='fu'><a href='translate.html'>get_locale</a></span>(), <span class='no'>...</span>)</pre>
|
<span class='fu'>ab_property</span>(<span class='no'>x</span>, <span class='kw'>property</span> <span class='kw'>=</span> <span class='st'>"name"</span>, <span class='kw'>language</span> <span class='kw'>=</span> <span class='fu'><a href='translate.html'>get_locale</a></span>(), <span class='no'>...</span>)</pre>
|
||||||
|
|
||||||
<h2 class="hasAnchor" id="arguments"><a class="anchor" href="#arguments"></a>Arguments</h2>
|
<h2 class="hasAnchor" id="arguments"><a class="anchor" href="#arguments"></a>Arguments</h2>
|
||||||
|
|
|
@ -379,7 +379,7 @@
|
||||||
</tr><tr>
|
</tr><tr>
|
||||||
|
|
||||||
<td>
|
<td>
|
||||||
<p><code><a href="ab_property.html">ab_name()</a></code> <code><a href="ab_property.html">ab_atc()</a></code> <code><a href="ab_property.html">ab_cid()</a></code> <code><a href="ab_property.html">ab_synonyms()</a></code> <code><a href="ab_property.html">ab_tradenames()</a></code> <code><a href="ab_property.html">ab_group()</a></code> <code><a href="ab_property.html">ab_atc_group1()</a></code> <code><a href="ab_property.html">ab_atc_group2()</a></code> <code><a href="ab_property.html">ab_ddd()</a></code> <code><a href="ab_property.html">ab_property()</a></code> </p>
|
<p><code><a href="ab_property.html">ab_name()</a></code> <code><a href="ab_property.html">ab_atc()</a></code> <code><a href="ab_property.html">ab_cid()</a></code> <code><a href="ab_property.html">ab_synonyms()</a></code> <code><a href="ab_property.html">ab_tradenames()</a></code> <code><a href="ab_property.html">ab_group()</a></code> <code><a href="ab_property.html">ab_atc_group1()</a></code> <code><a href="ab_property.html">ab_atc_group2()</a></code> <code><a href="ab_property.html">ab_ddd()</a></code> <code><a href="ab_property.html">ab_info()</a></code> <code><a href="ab_property.html">ab_property()</a></code> </p>
|
||||||
</td>
|
</td>
|
||||||
<td><p>Property of an antibiotic</p></td>
|
<td><p>Property of an antibiotic</p></td>
|
||||||
</tr><tr>
|
</tr><tr>
|
||||||
|
|
Loading…
Reference in New Issue