mirror of
https://github.com/msberends/AMR.git
synced 2025-07-08 16:42:10 +02:00
(v1.4.0.9021) more robust class setting
This commit is contained in:
@ -69,13 +69,14 @@ age_groups(ages, "children")
|
||||
|
||||
\donttest{
|
||||
# resistance of ciprofloxacin per age group
|
||||
library(dplyr)
|
||||
example_isolates \%>\%
|
||||
filter_first_isolate() \%>\%
|
||||
filter(mo == as.mo("E. coli")) \%>\%
|
||||
group_by(age_group = age_groups(age)) \%>\%
|
||||
select(age_group, CIP) \%>\%
|
||||
ggplot_rsi(x = "age_group", minimum = 0)
|
||||
if (require("dplyr")) {
|
||||
example_isolates \%>\%
|
||||
filter_first_isolate() \%>\%
|
||||
filter(mo == as.mo("E. coli")) \%>\%
|
||||
group_by(age_group = age_groups(age)) \%>\%
|
||||
select(age_group, CIP) \%>\%
|
||||
ggplot_rsi(x = "age_group", minimum = 0)
|
||||
}
|
||||
}
|
||||
}
|
||||
\seealso{
|
||||
|
@ -40,7 +40,6 @@ On our website \url{https://msberends.github.io/AMR/} you can find \href{https:/
|
||||
\examples{
|
||||
\donttest{
|
||||
# transform existing disk zones to the `disk` class
|
||||
library(dplyr)
|
||||
df <- data.frame(microorganism = "E. coli",
|
||||
AMP = 20,
|
||||
CIP = 14,
|
||||
|
Reference in New Issue
Block a user