We can now add the interpretation of MDR-TB to our data set. You can
use:
@@ -455,40 +455,40 @@ Unique: 5
1
Mono-resistant
-3247
-64.94%
-3247
-64.94%
+3307
+66.14%
+3307
+66.14%
2
Negative
-986
-19.72%
-4233
-84.66%
+934
+18.68%
+4241
+84.82%
3
Multi-drug-resistant
-434
-8.68%
-4667
-93.34%
+436
+8.72%
+4677
+93.54%
4
Poly-resistant
-231
-4.62%
-4898
-97.96%
+235
+4.70%
+4912
+98.24%
5
Extensively drug-resistant
-102
-2.04%
+88
+1.76%
5000
100.00%
diff --git a/articles/PCA.html b/articles/PCA.html
index 0b50d0ad..e36e32da 100644
--- a/articles/PCA.html
+++ b/articles/PCA.html
@@ -38,7 +38,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/articles/WHONET.html b/articles/WHONET.html
index ae3a5531..86bf5fb0 100644
--- a/articles/WHONET.html
+++ b/articles/WHONET.html
@@ -38,7 +38,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/articles/datasets.html b/articles/datasets.html
index 5f9153c9..2be5624d 100644
--- a/articles/datasets.html
+++ b/articles/datasets.html
@@ -38,7 +38,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
@@ -193,7 +193,7 @@
-
AMR 2.0.0.9045
+
AMR 2.1.0
-
New
+
New
Regarding clinical breakpoints:
Clinical breakpoints and intrinsic resistance of EUCAST 2023 and CLSI 2023 have been added to the clinical_breakpoints
data set for usage in as.sir()
. EUCAST 2023 (v13.0) is now the new default guideline for all MIC and disks diffusion interpretations
The EUCAST dosage guideline of v13.0 has been added to the dosage
data set
@@ -178,7 +178,7 @@
Added microbial codes for Gram-negative/positive anaerobic bacteria
-
Changed
+
Changed
Updated algorithm of as.mo()
by giving more weight to fungi
Fixed clinical breakpoints errors introduced by the source we import the rules from
diff --git a/pkgdown.yml b/pkgdown.yml
index 600cb52e..efea05d9 100644
--- a/pkgdown.yml
+++ b/pkgdown.yml
@@ -11,7 +11,7 @@ articles:
other_pkg: other_pkg.html
resistance_predict: resistance_predict.html
welcome_to_AMR: welcome_to_AMR.html
-last_built: 2023-07-14T08:55Z
+last_built: 2023-07-16T14:22Z
urls:
reference: https://msberends.github.io/AMR/reference
article: https://msberends.github.io/AMR/articles
diff --git a/reference/AMR-deprecated.html b/reference/AMR-deprecated.html
index 88ec17fb..69985981 100644
--- a/reference/AMR-deprecated.html
+++ b/reference/AMR-deprecated.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/AMR-options.html b/reference/AMR-options.html
index ef76674c..604f2b6d 100644
--- a/reference/AMR-options.html
+++ b/reference/AMR-options.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/AMR.html b/reference/AMR.html
index aea57c5e..34d61489 100644
--- a/reference/AMR.html
+++ b/reference/AMR.html
@@ -24,7 +24,7 @@ The AMR package is available in English, Chinese, Czech, Danish, Dutch, Finnish,
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/WHOCC.html b/reference/WHOCC.html
index 280b498f..eae2ba92 100644
--- a/reference/WHOCC.html
+++ b/reference/WHOCC.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/WHONET.html b/reference/WHONET.html
index eeda9211..b8e46a70 100644
--- a/reference/WHONET.html
+++ b/reference/WHONET.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/ab_from_text.html b/reference/ab_from_text.html
index ddd4941a..0c142e60 100644
--- a/reference/ab_from_text.html
+++ b/reference/ab_from_text.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/ab_property.html b/reference/ab_property.html
index 549e81f6..a12cb07b 100644
--- a/reference/ab_property.html
+++ b/reference/ab_property.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/add_custom_antimicrobials.html b/reference/add_custom_antimicrobials.html
index 3f970be9..810d71f7 100644
--- a/reference/add_custom_antimicrobials.html
+++ b/reference/add_custom_antimicrobials.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/add_custom_microorganisms.html b/reference/add_custom_microorganisms.html
index bfbd06a6..475d9256 100644
--- a/reference/add_custom_microorganisms.html
+++ b/reference/add_custom_microorganisms.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/age.html b/reference/age.html
index 04dc3221..2ddc011e 100644
--- a/reference/age.html
+++ b/reference/age.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
@@ -222,16 +222,16 @@
df
#> birth_date age age_exact age_at_y2k
-#> 1 1967-12-22 55 55.55890 32
-#> 2 1967-05-10 56 56.17808 32
-#> 3 1947-01-16 76 76.49041 52
-#> 4 1980-02-08 43 43.42740 19
-#> 5 1988-03-15 35 35.33151 11
-#> 6 1955-07-31 67 67.95342 44
-#> 7 1991-04-20 32 32.23288 8
-#> 8 1966-02-16 57 57.40548 33
-#> 9 1964-12-30 58 58.53699 35
-#> 10 1998-09-24 24 24.80274 1
+#> 1 1967-02-24 56 56.38904 32
+#> 2 1989-12-18 33 33.57534 10
+#> 3 1981-03-15 42 42.33699 18
+#> 4 1935-10-19 87 87.73973 64
+#> 5 1987-11-07 35 35.68767 12
+#> 6 1995-11-05 27 27.69315 4
+#> 7 1953-11-09 69 69.68219 46
+#> 8 1970-04-17 53 53.24658 29
+#> 9 1950-04-25 73 73.22466 49
+#> 10 1937-07-08 86 86.02192 62
On this page
diff --git a/reference/age_groups.html b/reference/age_groups.html
index 3fea3a43..952ddc20 100644
--- a/reference/age_groups.html
+++ b/reference/age_groups.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/antibiogram.html b/reference/antibiogram.html
index d0f6d750..38cf9a41 100644
--- a/reference/antibiogram.html
+++ b/reference/antibiogram.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/antibiotic_class_selectors.html b/reference/antibiotic_class_selectors.html
index 381b349b..ff68eda2 100644
--- a/reference/antibiotic_class_selectors.html
+++ b/reference/antibiotic_class_selectors.html
@@ -12,7 +12,7 @@ In short, if you have a column name that resembles an antimicrobial drug, it wil
AMR (for R)
- 2.0.0.9045
+ 2.1.0
@@ -626,11 +626,11 @@ In short, if you have a column name that resembles an antimicrobial drug, it wil
#> # A tibble: 5 × 1
#> kefzol
#> <sir>
-#> 1 R
+#> 1 I
#> 2 I
#> 3 I
-#> 4 S
-#> 5 R
+#> 4 R
+#> 5 I
if ( require ( "dplyr" ) ) {
# get AMR for all aminoglycosides e.g., per ward:
diff --git a/reference/antibiotics.html b/reference/antibiotics.html
index 539d6972..03747e6a 100644
--- a/reference/antibiotics.html
+++ b/reference/antibiotics.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.ab.html b/reference/as.ab.html
index ca1f768e..fe7778ff 100644
--- a/reference/as.ab.html
+++ b/reference/as.ab.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.av.html b/reference/as.av.html
index c388e778..8bbb7eb6 100644
--- a/reference/as.av.html
+++ b/reference/as.av.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.disk.html b/reference/as.disk.html
index 608f9bfe..f4853d44 100644
--- a/reference/as.disk.html
+++ b/reference/as.disk.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.mic.html b/reference/as.mic.html
index 5373f25e..408c26cd 100644
--- a/reference/as.mic.html
+++ b/reference/as.mic.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.mo.html b/reference/as.mo.html
index a03366d1..7661ed87 100644
--- a/reference/as.mo.html
+++ b/reference/as.mo.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/as.sir.html b/reference/as.sir.html
index 1dc136e0..0092a56f 100644
--- a/reference/as.sir.html
+++ b/reference/as.sir.html
@@ -14,7 +14,7 @@ All breakpoints used for interpretation are publicly available in the clinical_b
AMR (for R)
- 2.0.0.9045
+ 2.1.0
@@ -567,19 +567,19 @@ A microorganism is categorised as "Resistant" when there is a high likelihood of
#> # A tibble: 13 × 13
#> datetime index ab_user mo_user ab mo input
#> <dttm> <int> <chr> <chr> <ab> <mo> <dbl>
-#> 1 2023-07-14 08:56:12 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16
-#> 2 2023-07-14 08:56:12 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18
-#> 3 2023-07-14 08:56:12 1 CIP Escherich… CIP B_[ORD]_ENTRBCTR 0.256
-#> 4 2023-07-14 08:56:12 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 8
-#> 5 2023-07-14 08:56:03 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 0.01
-#> 6 2023-07-14 08:56:03 2 AMX B_STRPT_P… AMX B_STRPT_PNMN 2
-#> 7 2023-07-14 08:56:03 3 AMX B_STRPT_P… AMX B_STRPT_PNMN 4
-#> 8 2023-07-14 08:56:03 4 AMX B_STRPT_P… AMX B_STRPT_PNMN 8
-#> 9 2023-07-14 08:56:03 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 2
-#> 10 2023-07-14 08:56:02 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16
-#> 11 2023-07-14 08:56:02 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18
-#> 12 2023-07-14 08:56:02 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 20
-#> 13 2023-07-14 08:56:02 1 ampicillin Strep pneu AMP B_STRPT_PNMN 18
+#> 1 2023-07-16 14:23:01 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16
+#> 2 2023-07-16 14:23:01 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18
+#> 3 2023-07-16 14:23:01 1 CIP Escherich… CIP B_[ORD]_ENTRBCTR 0.256
+#> 4 2023-07-16 14:23:00 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 8
+#> 5 2023-07-16 14:22:54 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 0.01
+#> 6 2023-07-16 14:22:54 2 AMX B_STRPT_P… AMX B_STRPT_PNMN 2
+#> 7 2023-07-16 14:22:54 3 AMX B_STRPT_P… AMX B_STRPT_PNMN 4
+#> 8 2023-07-16 14:22:54 4 AMX B_STRPT_P… AMX B_STRPT_PNMN 8
+#> 9 2023-07-16 14:22:53 1 AMX B_STRPT_P… AMX B_STRPT_PNMN 2
+#> 10 2023-07-16 14:22:53 1 TOB Escherich… TOB B_[ORD]_ENTRBCTR 16
+#> 11 2023-07-16 14:22:53 1 GEN Escherich… GEN B_[ORD]_ENTRBCTR 18
+#> 12 2023-07-16 14:22:52 1 AMP Escherich… AMP B_[ORD]_ENTRBCTR 20
+#> 13 2023-07-16 14:22:52 1 ampicillin Strep pneu AMP B_STRPT_PNMN 18
#> # ℹ 6 more variables: outcome <sir>, method <chr>, breakpoint_S_R <chr>,
#> # guideline <chr>, ref_table <chr>, uti <lgl>
diff --git a/reference/atc_online.html b/reference/atc_online.html
index 856bf15c..0ceb6e76 100644
--- a/reference/atc_online.html
+++ b/reference/atc_online.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/av_from_text.html b/reference/av_from_text.html
index d4fcd8f0..d110da34 100644
--- a/reference/av_from_text.html
+++ b/reference/av_from_text.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/av_property.html b/reference/av_property.html
index 9bd5ac3a..13757c3d 100644
--- a/reference/av_property.html
+++ b/reference/av_property.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/availability.html b/reference/availability.html
index 13a253f5..66767773 100644
--- a/reference/availability.html
+++ b/reference/availability.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/bug_drug_combinations.html b/reference/bug_drug_combinations.html
index 7fcf33f1..3845512d 100644
--- a/reference/bug_drug_combinations.html
+++ b/reference/bug_drug_combinations.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/clinical_breakpoints.html b/reference/clinical_breakpoints.html
index e83a3cec..5007c546 100644
--- a/reference/clinical_breakpoints.html
+++ b/reference/clinical_breakpoints.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/count.html b/reference/count.html
index c2676231..4ac6b780 100644
--- a/reference/count.html
+++ b/reference/count.html
@@ -12,7 +12,7 @@ count_resistant() should be used to count resistant isolates, count_susceptible(
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/custom_eucast_rules.html b/reference/custom_eucast_rules.html
index 35a144f3..9cee6737 100644
--- a/reference/custom_eucast_rules.html
+++ b/reference/custom_eucast_rules.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/dosage.html b/reference/dosage.html
index ab399b5a..6d00bacc 100644
--- a/reference/dosage.html
+++ b/reference/dosage.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/eucast_rules.html b/reference/eucast_rules.html
index 85f2d7f6..7290b5bc 100644
--- a/reference/eucast_rules.html
+++ b/reference/eucast_rules.html
@@ -12,7 +12,7 @@ To improve the interpretation of the antibiogram before EUCAST rules are applied
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/example_isolates.html b/reference/example_isolates.html
index 3ba30453..4c5f5bd7 100644
--- a/reference/example_isolates.html
+++ b/reference/example_isolates.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/example_isolates_unclean.html b/reference/example_isolates_unclean.html
index a8c58969..c466b7e5 100644
--- a/reference/example_isolates_unclean.html
+++ b/reference/example_isolates_unclean.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/first_isolate.html b/reference/first_isolate.html
index 918b1d92..0a29f168 100644
--- a/reference/first_isolate.html
+++ b/reference/first_isolate.html
@@ -12,7 +12,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/g.test.html b/reference/g.test.html
index b06e9ca3..1f7b9ef7 100644
--- a/reference/g.test.html
+++ b/reference/g.test.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
diff --git a/reference/get_episode.html b/reference/get_episode.html
index 0e56f879..ea1c653f 100644
--- a/reference/get_episode.html
+++ b/reference/get_episode.html
@@ -10,7 +10,7 @@
AMR (for R)
- 2.0.0.9045
+ 2.1.0
@@ -263,27 +263,28 @@
df <- example_isolates [ sample ( seq_len ( 2000 ) , size = 100 ) , ]
get_episode ( df $ date , episode_days = 60 ) # indices
-#> [1] 38 19 11 11 7 35 22 3 45 19 40 6 29 44 48 19 26 15 5 39 46 29 47 13 47
-#> [26] 34 40 9 4 11 4 41 39 30 16 32 1 46 24 27 43 30 38 7 6 49 11 48 11 16
-#> [51] 21 15 11 17 47 4 12 28 23 5 8 6 12 33 31 19 15 28 8 26 18 42 10 37 13
-#> [76] 39 2 4 48 1 40 10 24 45 26 12 38 40 17 25 20 8 13 29 8 50 31 36 42 14
+#> [1] 1 2 47 6 49 16 21 28 7 14 45 35 38 30 46 13 37 42 33 13 44 3 34 10 22
+#> [26] 35 34 15 4 4 23 18 23 6 17 24 31 43 13 19 31 9 26 32 39 38 12 23 11 7
+#> [51] 21 14 32 28 48 45 35 36 31 29 27 15 27 39 14 39 15 9 28 31 39 15 5 17 24
+#> [76] 32 20 41 28 46 29 49 44 34 49 37 40 3 13 10 35 8 22 10 25 28 2 10 10 40
is_new_episode ( df $ date , episode_days = 60 ) # TRUE/FALSE
-#> [1] TRUE TRUE TRUE FALSE TRUE TRUE TRUE TRUE TRUE FALSE TRUE TRUE
-#> [13] TRUE TRUE TRUE FALSE TRUE TRUE TRUE TRUE TRUE FALSE TRUE TRUE
-#> [25] FALSE TRUE FALSE TRUE TRUE FALSE FALSE TRUE FALSE TRUE TRUE TRUE
-#> [37] TRUE FALSE TRUE TRUE TRUE FALSE FALSE FALSE FALSE TRUE FALSE FALSE
-#> [49] FALSE FALSE TRUE FALSE FALSE TRUE FALSE FALSE TRUE TRUE TRUE FALSE
-#> [61] TRUE FALSE FALSE TRUE TRUE FALSE FALSE FALSE FALSE FALSE TRUE TRUE
-#> [73] TRUE TRUE FALSE FALSE TRUE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
-#> [85] FALSE FALSE FALSE FALSE FALSE TRUE TRUE FALSE FALSE FALSE FALSE TRUE
-#> [97] FALSE TRUE FALSE TRUE
+#> [1] TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE
+#> [13] TRUE TRUE TRUE TRUE TRUE TRUE TRUE FALSE TRUE TRUE TRUE TRUE
+#> [25] TRUE FALSE FALSE TRUE TRUE FALSE TRUE TRUE FALSE FALSE TRUE TRUE
+#> [37] TRUE TRUE FALSE TRUE FALSE TRUE TRUE TRUE TRUE FALSE TRUE FALSE
+#> [49] TRUE FALSE FALSE FALSE FALSE FALSE TRUE FALSE FALSE TRUE FALSE TRUE
+#> [61] TRUE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE FALSE
+#> [73] TRUE FALSE FALSE FALSE TRUE TRUE FALSE FALSE FALSE FALSE FALSE FALSE
+#> [85] FALSE FALSE TRUE FALSE FALSE FALSE FALSE TRUE FALSE FALSE TRUE FALSE
+#> [97] FALSE FALSE FALSE FALSE
# filter on results from the third 60-day episode only, using base R
df [ which ( get_episode ( df $ date , 60 ) == 3 ) , ]
-#> # A tibble: 1 × 46
-#> date patient age gender ward mo PEN OXA FLC AMX
-#> <date> <chr> <dbl> <chr> <chr> <mo> <sir> <sir> <sir> <sir>
-#> 1 2002-06-06 24D393 20 F Clinical B_ESCHR_COLI R NA NA NA
+#> # A tibble: 2 × 46
+#> date patient age gender ward mo PEN OXA FLC AMX
+#> <date> <chr> <dbl> <chr> <chr> <mo> <sir> <sir> <sir> <sir>
+#> 1 2002-12-13 285137 78 F ICU B_ESCHR_COLI R NA NA NA
+#> 2 2002-10-18 E55128 57 F ICU B_STPHY_AURS R NA S R
#> # ℹ 36 more variables: AMC <sir>, AMP <sir>, TZP <sir>, CZO <sir>, FEP <sir>,
#> # CXM <sir>, FOX <sir>, CTX <sir>, CAZ <sir>, CRO <sir>, GEN <sir>,
#> # TOB <sir>, AMK <sir>, KAN <sir>, TMP <sir>, SXT <sir>, NIT <sir>,
@@ -317,19 +318,19 @@
arrange ( patient , condition , date )
}
#> # A tibble: 100 × 4
-#> # Groups: patient, condition [99]
+#> # Groups: patient, condition [98]
#> patient date condition new_episode
#> <chr> <date> <chr> <lgl>
-#> 1 005088 2007-08-22 C TRUE
-#> 2 018637 2005-09-28 B TRUE
-#> 3 021368 2016-03-25 A TRUE
-#> 4 032343 2003-06-09 A TRUE
-#> 5 058917 2002-11-14 C TRUE
-#> 6 05C73F 2006-01-12 B TRUE
-#> 7 092034 2006-06-12 B TRUE
-#> 8 0D7D34 2011-03-19 B TRUE
-#> 9 0DBF93 2015-10-12 B TRUE
-#> 10 0E2483 2007-08-10 C TRUE
+#> 1 001213 2009-08-03 B TRUE
+#> 2 004531 2013-12-02 A TRUE
+#> 3 008218 2009-05-05 A TRUE
+#> 4 023456 2009-11-02 A TRUE
+#> 5 023456 2011-04-25 A TRUE
+#> 6 047634 2004-06-28 B TRUE
+#> 7 07545C 2010-02-08 C TRUE
+#> 8 083080 2012-04-16 A TRUE
+#> 9 083080 2010-02-25 B TRUE
+#> 10 088256 2003-01-25 B TRUE
#> # ℹ 90 more rows
if ( require ( "dplyr" ) ) {
@@ -343,19 +344,19 @@
arrange ( patient , ward , date )
}
#> # A tibble: 100 × 5
-#> # Groups: ward, patient [96]
-#> ward date patient new_index new_logical
-#> <chr> <date> <chr> <int> <lgl>
-#> 1 Clinical 2007-08-22 005088 1 TRUE
-#> 2 Clinical 2005-09-28 018637 1 TRUE
-#> 3 Outpatient 2016-03-25 021368 1 TRUE
-#> 4 Clinical 2003-06-09 032343 1 TRUE
-#> 5 ICU 2002-11-14 058917 1 TRUE
-#> 6 Clinical 2006-01-12 05C73F 1 TRUE
-#> 7 ICU 2006-06-12 092034 1 TRUE
-#> 8 ICU 2011-03-19 0D7D34 1 TRUE
-#> 9 Clinical 2015-10-12 0DBF93 1 TRUE
-#> 10 ICU 2007-08-10 0E2483 1 TRUE
+#> # Groups: ward, patient [95]
+#> ward date patient new_index new_logical
+#> <chr> <date> <chr> <int> <lgl>
+#> 1 Clinical 2009-08-03 001213 1 TRUE
+#> 2 Clinical 2013-12-02 004531 1 TRUE
+#> 3 Clinical 2009-05-05 008218 1 TRUE
+#> 4 Clinical 2009-11-02 023456 1 TRUE
+#> 5 Clinical 2011-04-25 023456 2 TRUE
+#> 6 Clinical 2004-06-28 047634 1 TRUE
+#> 7 Clinical 2010-02-08 07545C 1 TRUE
+#> 8 Clinical 2010-02-25 083080 1 TRUE
+#> 9 Clinical 2012-04-16 083080 2 TRUE
+#> 10 ICU 2003-01-25 088256 1 TRUE
#> # ℹ 90 more rows
if ( require ( "dplyr" ) ) {
@@ -371,9 +372,9 @@
#> # A tibble: 3 × 5
#> ward n_patients n_episodes_365 n_episodes_60 n_episodes_30
#> <chr> <int> <int> <int> <int>
-#> 1 Clinical 59 14 41 48
-#> 2 ICU 32 11 25 28
-#> 3 Outpatient 5 4 5 5
+#> 1 Clinical 57 13 35 43
+#> 2 ICU 27 9 20 23
+#> 3 Outpatient 11 5 11 11
# grouping on patients and microorganisms leads to the same
# results as first_isolate() when using 'episode-based':
@@ -391,7 +392,7 @@
identical ( x , y )
}
-#> [1] FALSE
+#> [1] TRUE
# but is_new_episode() has a lot more flexibility than first_isolate(),
# since you can now group on anything that seems relevant:
@@ -403,18 +404,18 @@
}
#> # A tibble: 100 × 4
#> # Groups: patient, mo, ward [98]
-#> patient mo ward flag_episode
-#> <chr> <mo> <chr> <lgl>
-#> 1 C34429 B_PROTS_MRBL Clinical TRUE
-#> 2 8B8705 B_ESCHR_COLI Clinical TRUE
-#> 3 690605 B_STRPT_DYSG ICU TRUE
-#> 4 400169 B_SERRT_MRCS ICU TRUE
-#> 5 F35553 B_ENTRBC_CLOC ICU TRUE
-#> 6 A97263 B_KLBSL_PNMN Clinical TRUE
-#> 7 329273 B_STRPT_PNMN Clinical TRUE
-#> 8 24D393 B_ESCHR_COLI Clinical TRUE
-#> 9 305134 B_PROTS_VLGR ICU TRUE
-#> 10 0E2483 B_ESCHR_COLI ICU TRUE
+#> patient mo ward flag_episode
+#> <chr> <mo> <chr> <lgl>
+#> 1 F41248 B_STPHY_AURS Clinical TRUE
+#> 2 871360 B_STPHY_EPDR Clinical TRUE
+#> 3 545300 B_KLBSL_PNMN Clinical TRUE
+#> 4 D63414 B_PROTS_MRBL Clinical TRUE
+#> 5 4B1971 B_ESCHR_COLI ICU TRUE
+#> 6 690B42 B_ESCHR_COLI ICU TRUE
+#> 7 1710B8 B_PROTS_MRBL Clinical TRUE
+#> 8 308D34 B_STPHY_CONS Clinical TRUE
+#> 9 419655 B_STRPT_PNMN ICU TRUE
+#> 10 904485 B_ESCHR_COLI Outpatient TRUE
#> # ℹ 90 more rows
# }
diff --git a/reference/ggplot_pca.html b/reference/ggplot_pca.html
index bc988397..d2a519be 100644
--- a/reference/ggplot_pca.html
+++ b/reference/ggplot_pca.html
@@ -10,7 +10,7 @@