1
0
mirror of https://github.com/msberends/AMR.git synced 2026-05-14 07:50:46 +02:00
Commit Graph

55 Commits

Author SHA1 Message Date
Matthijs Berends
24f24ecaf8 Generalise interpretive rules for multi-guideline support (#268) (#283)
* Generalise interpretive rules for multi-guideline support (#268)

- Rename data-raw/eucast_rules.tsv → interpretive_rules.tsv; add rule.provider
  column (value: "EUCAST") to distinguish future CLSI rows
- Rename EUCAST_RULES_DF → INTERPRETIVE_RULES_DF in _pre_commit_checks.R;
  filter by rule.provider == guideline when applying rules in interpretive_rules()
- Rename custom_eucast_rules() → custom_interpretive_rules() with new S3 class
  "custom_interpretive_rules"; old function becomes a deprecated wrapper in
  zz_deprecated.R; backward-compat S3 dispatch shims added for old class
- Remove stop_if(guideline == "CLSI", ...) so clsi_rules() no longer errors
- Add .onLoad shim in zzz.R to create INTERPRETIVE_RULES_DF from EUCAST_RULES_DF
  for transitional compatibility until sysdata.rda is regenerated

https://claude.ai/code/session_01D46BTsfJSPo3HnLWp3PRkP

* Fix namespace load failure: remove assignInNamespace from .onLoad (#268)

assignInNamespace cannot add NEW bindings to a locked package namespace
(R locks namespace bindings before .onLoad runs). Replace the .onLoad
shim with a runtime fallback inside interpretive_rules(): if
INTERPRETIVE_RULES_DF is absent (pre-regeneration sysdata.rda), derive
it from EUCAST_RULES_DF by adding the rule.provider column. This also
fixes the screening_abx line to reuse the already-resolved
interpretive_rules_df_total instead of a bare INTERPRETIVE_RULES_DF
reference.

https://claude.ai/code/session_01D46BTsfJSPo3HnLWp3PRkP

* fixes

* fixes

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-01 18:38:51 +01:00
e2102c081a (v3.0.1.9030) fix R 3.6 2026-03-07 18:07:24 +01:00
daab605ca4 (v3.0.1.9028) fix unique CIDs 2026-03-06 18:53:42 +01:00
46f80b1378 (v2.1.1.9288) mdro fix 2025-06-01 15:35:04 +02:00
2461631bce (v2.1.1.9268) WISCA vignette, antibiogram sorting, fix translations 2025-05-01 14:45:21 +02:00
40d7a971c3 (v2.1.1.9236) documentation 2025-04-12 11:46:42 +02:00
36fd99e1f4 (v2.1.1.9235) New website! 2025-04-08 15:54:30 +01:00
8deaf2c8eb (v2.1.1.9224) skip tests on cran 2025-03-20 23:29:21 +01:00
58d7aa8790 (v2.1.1.9199) fix eucast 2025-03-14 13:43:22 +01:00
9aab129ea6 (v2.1.1.9195) add BTL-S, fix ranks in unknown microorganisms 2025-03-13 14:30:14 +01:00
a7ef22a21e (v2.1.1.9194) new argument for missing R breakpoints - updated from WHONET 2025-03-12 16:24:38 +01:00
f7938289eb (v2.1.1.9186) replace antibiotics with antimicrobials! 2025-03-07 20:43:26 +01:00
07efc292bc (v2.1.1.9163) cleanup 2025-02-27 14:04:29 +01:00
f03933940c (v2.1.1.9131) implement testthat 2025-01-27 21:43:10 +01:00
d8c91d5876 (v1.6.0.9031) tinytest unit tests 2021-05-15 21:36:22 +02:00
0d29bde693 (v1.5.0.9030) as.ab() speed improvement 2021-03-05 10:32:09 +01:00
ddf88345f1 (v1.5.0.9028) Updated taxonomy until March 2021 2021-03-04 23:28:32 +01:00
062c49fca1 (v1.5.0.9022) mo properties speed improvement 2021-02-21 22:56:35 +01:00
2eca8c3f01 (v1.5.0.9014) only_rsi_columns, is.rsi.eligible improvement 2021-02-02 23:57:35 +01:00
1a88caa119 (v1.5.0.9009) unit test fixes 2021-01-22 10:55:07 +01:00
d014955ce0 (v.1.5.0.9000) implementation of EUCAST rules v11 (2021) 2021-01-12 22:08:04 +01:00
8b52f9b1be (v1.4.0.9047) unit tests 2020-12-27 00:30:28 +01:00
e03b3c96d3 (v1.4.0.9030) as.mo() fix for known lab codes 2020-12-03 16:59:04 +01:00
28e77680c5 (v1.4.0) matching score update 2020-10-08 11:16:03 +02:00
4e0374af29 (v1.3.0.9035) mdro() for EUCAST 3.2, examples cleanup 2020-09-29 23:35:46 +02:00
c5f7294381 (v1.3.0) skip more CRAN tests 2020-07-31 10:50:08 +02:00
09fba38ea6 (v1.2.0.9035) as.mo() speed improvement 2020-07-22 10:24:23 +02:00
76fc8e1b14 (v1.2.0.9026) move to github 2020-07-08 14:48:06 +02:00
86d44054f0 (v1.1.0.9020) updated taxonomy 2020-05-27 16:37:49 +02:00
19703eb5d3 (v1.1.0.9012) lose dependencies 2020-05-19 12:08:49 +02:00
7f3da74b17 (v1.1.0.9004) lose dependencies 2020-05-16 13:05:47 +02:00
9b8b02960e (v0.9.0.9023) EUCAST 2020 guidelines 2020-02-14 19:54:13 +01:00
ced1a7b7fa (v0.9.0.9008) Happy new year! Add lifecycles 2020-01-05 17:22:09 +01:00
ba3ce77f02 (v0.9.0.9005) as.mo for G. species 2019-12-21 10:56:06 +01:00
3e5ab53209 (v0.8.0.9002) eucast_rules() fix for S. maltophilia 2019-10-23 14:48:25 +02:00
00cdb498a0 (v0.7.1.9102) lintr 2019-10-11 17:21:02 +02:00
b6653a620a (v0.7.1.9093) as.ab() fix 2019-10-06 21:07:38 +02:00
3596adb295 (v0.7.1.9076) mo codes 2019-09-20 12:33:05 +02:00
cd178ee569 (v0.7.1.9072) key_antibiotics() for foreign systems 2019-09-12 15:08:53 +02:00
8f674e19bb (v0.7.0.9005) ab algorithm update 2019-06-11 14:18:25 +02:00
4bac768557 (v0.6.1.9048) data creation fox 2019-05-31 21:01:14 +02:00
27380fa021 fixes for microorganisms.codes 2019-05-28 16:50:40 +02:00
cc403169c6 first isolate missing dates fix 2019-05-13 14:56:23 +02:00
68cc7ef0d0 new antibiotics 2019-05-10 16:44:59 +02:00
fbc9191b13 new EUCAST rules algorithm 2019-04-05 18:47:39 +02:00
afd12d5486 ci fixes 2019-03-26 14:42:56 +01:00
54162522bd age_groups fix 2019-02-27 11:36:12 +01:00
7f155c4e3a small units test 2019-02-22 00:19:37 +01:00
6c542268be unit tests 2019-02-21 23:32:30 +01:00
bd2a256969 unit test 2019-02-21 19:15:17 +01:00