Commit Graph
100 Commits
Author SHA1 Message Date
dr. M.S. (Matthijs) Berends 414f41ba22 Rebuild clinical_breakpoints, and add the NEWS entries and version bump for this PR
The rebuild uses the WHONET files of today, and holds the changes of #326, #327, #328, #329 and #331. The files in data-raw/datasets are not regenerated yet.
2026-11-02 18:27:17 +01:00
dr. M.S. (Matthijs) Berends d904ea5afb Merge remote-tracking branch 'origin/main' into breakpoints 2026-11-02 18:26:08 +01:00
dr. M.S. (Matthijs) Berends fbdfb0a071 Keep only EUCAST blocking rows that have an effect on as.sir() (#326)
The new internal blocking_row_is_needed() defines this: as.sir() must give another result without the row, so the definition follows the fallback path of as.sir() itself. The build removes all rows without an effect, and the new strict test checks all rows of the latest guideline, and for all years that a blocking row has a breakpoint to block.

This replaces the separate taxonomic comparison, handles the points of the review on this pruning, and keeps the sites of blocking rows, which `site` in as.sir() now uses.
2026-11-02 18:26:08 +01:00
dr. M.S. (Matthijs) Berends 472c84d20d Capture more EUCAST breakpoints from the Notes, using regular expressions only (#329)
Added: the oxacillin disk for S. pseudintermedius and related species, the oxacillin MIC for coagulase-negative staphylococci, mupirocin for nasal decolonisation, and meropenem in other infections for N. meningitidis. The Bacteroides statement is now matched as a pattern, and other wording stops the script.

The script documents why statements are left out, e.g., the oxacillin statements for S. aureus, S. lugdunensis and S. saprophyticus are hedged ("mostly methicillin resistant"), unlike those for cefoxitin.
2026-11-02 17:47:28 +01:00
dr. M.S. (Matthijs) Berends 2c98dac7ae Store all screening breakpoints under screening agents, and add these agents to antimicrobials (#328)
Implements the decisions ticked in #328, and the behaviour specified in https://github.com/msberends/AMR/pull/339#issuecomment-6577438074: `include_screening` now defaults to NULL, using screening breakpoints for screening agents only. With TRUE, a regular agent also takes these breakpoints, and with FALSE a screening agent gives NA with a note.

- antimicrobials gains 13 screening agents, e.g. GEN-S, ERY-S and STR1-S
- GEH and STH rows move to GEN-S and STR1-S, and as.sir() keeps accepting both codes
- Topical cut-off values move to -S agents with site "Topical"
- WHONET-based rows move as ticked, including CLSI cefoxitin for staphylococci and pefloxacin for Salmonella, and EUCAST 2012-2018 cefoxitin MIC
- Clinical breakpoints that EUCAST also allows as a screening test get a copy under the -S agent
2026-11-02 17:31:46 +01:00
dr. M.S. (Matthijs) Berends fab20c5eaa Leave EUCAST breakpoints in brackets out of clinical_breakpoints, and document where they are kept (#327)
as.sir() treats them as absent, so it can use PK/PD breakpoints or, for unknown `uti`, UTI breakpoints. The values stay available in data-raw/breakpoints_eucast_raw.csv, to which the manual now points. Organisms that a table excludes stay excluded, since these have their own blocking rows.

This also fixes the change for unknown `uti` of the previous commit: a blocking row only gives way to an actual UTI breakpoint, not to a UTI row without breakpoints.
2026-11-02 17:03:47 +01:00
dr. M.S. (Matthijs) Berends 4c4a7d4392 Add site to as.sir(), and use UTI breakpoints for unknown uti if no other breakpoint exists
`site` takes fixed codes, e.g. "meningitis" or "iv", and can be a column. With `site = NA`, any fitting breakpoint can apply, from most to least systemic. With a site set, breakpoints for contradicting sites are left out, while a breakpoint without a site still applies, and the result is NA if only contradicting sites exist, without falling back to PK/PD. `uti = TRUE` stays available and equals `site = "uti"`. Every choice is noted in sir_interpretation_history(), including the site that was used.

For unknown `uti`, a blocking row without a UTI status no longer overrides a UTI breakpoint at the same taxonomic level. A `uti` vector mixing NA with TRUE or FALSE no longer gives an error.

Veterinary sites are not part of the fixed codes yet, and are treated as breakpoints without a site.
2026-11-02 16:59:07 +01:00
dr. M.S. (Matthijs) Berends 5eed396dce Store EUCAST MIC breakpoints exactly as published, and compare dilutions in as.sir() (#331)
The reproduction script no longer maps MIC breakpoints to AMR:::COMMON_MIC_VALUES, and also keeps the off-scale S breakpoint of 0.001 mg/L. as.sir() compares through the new internal mic_dilution_level(), so that e.g. an MIC of 0.032 and a breakpoint of 0.03 are the same dilution, and shows the published breakpoints in sir_interpretation_history().

Every parsed breakpoint now holds the address of its workbook cell in breakpoints_eucast_raw, and the script stops if a second reading of the workbooks with readxl does not find the value in that cell.

The data sets are rebuilt once, at the end of this PR.
2026-11-02 16:56:51 +01:00
dr. M.S. (Matthijs) Berends 844e2581ee Test that Morganella is interpreted as reported, not as M. morganii (#330)
No code change was needed. Morganella follows Enterobacterales, except for imipenem and imipenem-relebactam, for which EUCAST gives rows for Morganellaceae or Morganella.
2026-11-02 16:55:36 +01:00
dr. M.S. (Matthijs) Berends 724a94a48f Add a tool to compare as.sir() results between builds, and apply the Bacteroides extension to zone diameters
The new compare_clinical_breakpoints.R compares the interpretations of two builds, and fails on any change that is not explained. A rebuild of main with pinned WHONET files reproduces all rows of clinical_breakpoints and microorganisms.codes.

The filter on MIC rows in the scope extensions is removed, since these now join on the method of each statement. It kept the DISK rows of the Bacteroides statement from being copied.
2026-11-02 16:55:36 +01:00
dr. M.S. (Matthijs) Berends 08fd165a60 (v3.1.0.9014) Fix the CI: replace a test unsupported by tinytest, run R 3.0 on Ubuntu 24.04, and use Python 3.12 for the PyPI package, since ubuntu-latest moved to Ubuntu 26.04 2026-10-30 14:55:00 +01:00
dr. M.S. (Matthijs) Berends 7f3c75ece7 (v3.1.0.9013) Add species groups and complexes to the intrinsic_resistant data set for every antimicrobial to which all their species are intrinsically resistant (fixes #338) 2026-10-30 13:37:25 +01:00
dr. M.S. (Matthijs) Berends aab0fcc479 (v3.1.0.9012) Use the native R pipe throughout the examples on the website home page, and fix a typo 2026-10-30 12:52:30 +01:00
dr. M.S. (Matthijs) Berends 944078c4bc (v3.1.0.9011) Use top_n_microorganisms() in the WISCA examples of the index, manual and vignette, and reword the WISCA prior weight warning to also cover small groups (#337) 2026-10-30 12:45:56 +01:00
dr. M.S. (Matthijs) Berends fdfdadae14 (v3.1.0.9010) Fix the systematic underestimation of WISCA coverage by only including pathogens that occur in a group and were tested for the regimen, and warn when the prior weight of rare pathogens is large (fixes #337) 2026-10-30 12:35:12 +01:00
dr. M.S. (Matthijs) Berends 92bb8931c5 (v3.1.0.9009) Fix the misaligned arrows in the message on taxonomically renamed microorganisms in colour-supporting consoles, by padding on the visible width instead of using format() (fixes #336) 2026-10-30 09:59:01 +01:00
dr. M.S. (Matthijs) Berends 4e806b3d40 (v3.1.0.9005) Fix the CI check on R-oldrel-5 by letting pak ignore readxl on R versions older than 4.2, and by not forcing suggested packages in R CMD check 2026-10-23 14:15:49 +02:00
dr. M.S. (Matthijs) BerendsandClaude Sonnet 5.5 5fc152ae94 (v3.1.0.9004) Document the columns argument of the tidymodels steps to fix the Rd usage warning in R CMD check
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-17 18:23:06 +02:00
dr. M.S. (Matthijs) Berends bd208429cd (v3.1.0.9003) Rewrite the manual index on the website for findability: sections ordered by task (cleaning data, interpreting results as SIR, analysing data), titles before function names, a filter field that also finds topics mentioning a term, and colours prepared for dark mode; also make the tidymodels extensions public in the manual and use consistent help page titles 2026-10-17 09:36:10 +02:00
dr. M.S. (Matthijs) Berends 52d9c4a9e7 (v3.1.0.9002) Add a release checklist (release.md) with all steps of a regular CRAN release 2026-10-16 14:23:01 +02:00
dr. M.S. (Matthijs) Berends 5a4387a141 (v3.1.0.9001) Update the MO code registry with the codes of release v3.1.0, and the versions in the bug report template 2026-10-16 14:19:48 +02:00
dr. M.S. (Matthijs) Berends 052edc4761 v3.1.0 2026-10-16 14:11:02 +02:00
dr. M.S. (Matthijs) Berends 6898472c8a (v3.0.1.9154) Shorten an example comment of wisca() to fix the Rd line widths NOTE 2026-10-16 06:32:46 +02:00
dr. M.S. (Matthijs) Berends 30021a9831 (v3.0.1.9153) Speed up mdro(), as.sir(), wisca() and wisca_plot() and the binding of mo vectors, fix PDR in the CMI 2012 guideline of mdro() being assigned to the wrong rows, and limit the stratified WISCA example to the 5 most common species 2026-10-16 06:08:26 +02:00
dr. M.S. (Matthijs) Berends 08aa47842e (v3.0.1.9152) Let a named colours_SIR without S, I or R use the default colours for these, which fixes the example of ggplot_sir() with colours = c(SI = "yellow"), let ggplot_sir() pass the facet as a value to facet_sir(), and make the test of the eucast_I default independent of the AMR_guideline option 2026-10-16 04:34:52 +02:00
dr. M.S. (Matthijs) Berends 43accd35d1 (v3.0.1.9151) Fix inconsistencies in the plotting functions and correct the translations of the interpretation categories
Plotting:
- Base colours and legends of interpreted MIC and disk values on the interpretation itself instead of matching colours
- Fix SDD in autoplot() for disks, the colours of barplot() for SIR values, and barplot() for MICs ignoring language and expand
- Match a named colours_SIR by name; let keep_operators = TRUE/FALSE in scale_*_mic() behave as "all"/"none"
- Let a named values in scale_*_sir() replace the colours it names, warn in scale_x_sir(), and pass other arguments on
- Let the default of eucast_I follow the guideline option, also for EUCAST before 2019
- Support unquoted column names in facet_sir() without evaluating them
- Correct the documentation and examples

Translations:
- Add SDD, NS, WT and NWT, and correct S, I, R and NI in 18 languages
- Sources of the terms for 'I': NAK via German laboratories (de), SZU national reference laboratory (cs), lex.dk (da), Karolinska University Hospital (sv), COESANT (es), Nordlab (fi), CA-SFM (fr); no by analogy with da and sv
- Not verified against an official source: ar, bn, el, hi, id, ja, ko, pl, ro, ru, sw, tr, uk, ur, vi, zh

Tests:
- Let the grouped antibiogram test use English so it passes in other locales
2026-10-15 22:25:20 +02:00
dr. M.S. (Matthijs) Berends b63263cc56 (v3.0.1.9150) Add the open issues found while correcting the WHONET codes to the taxonomy report 2026-10-15 21:31:28 +02:00
dr. M.S. (Matthijs) Berends eb9a9c2fa5 (v3.0.1.9149) Fix WHONET codes in microorganisms.codes that referred to unrelated microorganisms, let codes refer to the name they were named after and add a source column, and replace the fuzzy matching of WHONET names by exact matching with a guard against unreviewed remaps
WHONET names are now matched exactly (also outdated names, after removing qualifiers), then on GBIF identifier, and fuzzy results are only kept if consistent with that; otherwise the genus or UNKNOWN is used. A code refers to the record of the name it was named after (e.g. EAE is Enterobacter aerogenes) if that name refers to the same taxon. Every remap of an existing code to another taxon must be listed in data-raw/whonet_remaps_reviewed.csv; the 198 remaps of this rebuild were reviewed.
2026-10-15 21:08:04 +02:00
dr. M.S. (Matthijs) Berends 179eec584f (v3.0.1.9148) Store zone diameters without S category as blocking rows for EUCAST and as R-only rows for CLSI instead of capping them at 50 mm, let as.mo() return the complex for names such as 'Acinetobacter calcoaceticus-baumannii complex', make the breakpoint reproduction scripts stop on unchecked data defects and year-independent, and document that as.disk() returns NA above 50 mm
The full rebuild of clinical_breakpoints also assigns Salmonella serovars and the Bacteroides fragilis complex correctly and adds ECOFFs for Neocosmospora solani. The rebuilt microorganisms.codes is not included, since it remaps WHONET codes that need review first.
2026-10-15 17:05:41 +02:00
dr. M.S. (Matthijs) Berends fcfaa87f5d (v3.0.1.9147) Keep EUCAST blocking rows for infections other than UTI where EUCAST only gives a UTI breakpoint, e.g. breakpoints in brackets for aminoglycosides in Acinetobacter, and let as.sir() with unknown uti consistently prefer non-UTI breakpoints, use UTI breakpoints only if no others exist and note this in sir_interpretation_history() every time
The pruning of blocking rows in the EUCAST reproduction script now compares UTI status too, and the script is fixed for the renamed column of the as.ab() coercion cache. In clinical_breakpoints, only the blocking rows were replaced (356 organism/agent/method combinations newly blocked, none unblocked); other changes of a full rebuild, caused by taxonomy updates in the WHONET-based rows, are not included.
2026-10-15 14:55:57 +02:00
dr. M.S. (Matthijs) Berends d69e7fa740 (v3.0.1.9146) Correct the comment in the EUCAST reproduction script stating that breakpoints in brackets are excluded from clinical_breakpoints: they are kept as blocking rows without values 2026-10-15 12:13:56 +02:00
dr. M.S. (Matthijs) Berends 38ae865a07 Document all values of rank_index in the clinical_breakpoints data set, including species groups, and the stored value of EUCAST's off-scale S breakpoint 2026-10-15 10:37:40 +02:00
dr. M.S. (Matthijs) Berends 859b99e596 Format the month of the taxonomy update in English regardless of the system locale 2026-10-15 10:34:06 +02:00
dr. M.S. (Matthijs) Berends b3ecc01657 Show translated pathogen names instead of microorganism codes in grouped traditional antibiograms, including for unknown species 2026-10-15 10:31:07 +02:00
dr. M.S. (Matthijs) Berends 3db586a110 update logo to be perfect hexagon 2026-10-15 10:24:08 +02:00
dr. M.S. (Matthijs) Berends eb6d07e1fe Include isolates of unknown species in grouped antibiograms and in wisca(), which were silently excluded with the warning 'invalid microorganism code, NA generated' 2026-10-15 10:21:44 +02:00
dr. M.S. (Matthijs) Berends 3a87075ad3 Make the version formula for PRs in CLAUDE.md consistent with the pre-commit hook, which counts the commits before the new commit 2026-10-15 10:11:09 +02:00
dr. M.S. (Matthijs) Berends 0efc8826c8 Let aggregated analyses follow the guideline for the 'I' category in count_df(), proportion_df(), sir_df(), the plotting functions, antibiogram(), wisca(), and bug_drug_combinations(), deprecate combine_SI in favour of guideline, fix format() on bug_drug_combinations() counting I as resistant, and add a shared section 'Interpretation of SIR' 2026-10-15 09:58:21 +02:00
dr. M.S. (Matthijs) Berends dbd95ffa46 (v3.0.1.9137) Add the guideline argument to count_df(), proportion_df(), sir_df(), ggplot_sir(), geom_sir(), and labels_sir_count(), so that with CLSI the 'I' category is merged with R, and describe in the documentation of get_AMR_locale() that LANG takes precedence over LANGUAGE 2026-10-15 08:25:37 +02:00
dr. M.S. (Matthijs) Berends 46f5de1d36 (v3.0.1.9136) Fix the CI entry with a Dutch locale by using a UTF-8 locale that is installed on the runner, and skip the mo_source tests with skip_if() so that the tinytest harness for old R versions supports them 2026-10-15 00:11:07 +02:00
dr. M.S. (Matthijs) Berends 8b01bcb23c (v3.0.1.9135) Fix get_mo_source() removing the mo_source file at the default location, returning the wrong mo_source, and throwing an error after the original file was moved, and run the unit tests in CI also in a real interactive session and with a user setup, a Dutch locale, and CLSI as default guideline, with tests that no longer assume an English locale or EUCAST 2026-10-14 23:34:45 +02:00
dr. M.S. (Matthijs) Berends 4be7352843 (v3.0.1.9134) Add session cache assertions for separate as.ab() and as.mo() calls, for get_mo_source() without a file, and for real cache hits, which detect the cache being emptied in interactive sessions 2026-10-14 22:49:00 +02:00
dr. M.S. (Matthijs) Berends e88faf8d40 (v3.0.1.9133) Fix the as.mo() session cache being cleared on every call in interactive sessions without an mo_source file 2026-10-14 21:59:02 +02:00
dr. M.S. (Matthijs) Berends 1a1a3abed1 (v3.0.1.9132) Make translating around 50 times faster and coercion of unknown input in as.ab() up to 70 times faster with identical results, use DOIs instead of PubMed URLs, shorten an example line, and reword cran-comments.md 2026-10-14 20:17:28 +02:00
dr. M.S. (Matthijs) Berends 4115db67fa (v3.0.1.9131) Remove the list of breaking changes from cran-comments.md 2026-10-13 22:30:31 +02:00
dr. M.S. (Matthijs) Berends 8b3bc220ed (v3.0.1.9130) Add workflow to check reverse dependencies against the development version on every push to main, list WT/NWT for ECOFFs as breaking change, and update cran-comments.md for v3.1.0 2026-10-13 22:25:28 +02:00
dr. M.S. (Matthijs) Berends 9ebc33a59d (v3.0.1.9129) Add guideline argument to random_mic() and random_disk() so that values are based on one guideline version, make guideline years in examples, vignettes and website always the latest, and reword NEWS 2026-10-13 21:43:19 +02:00
dr. M.S. (Matthijs) Berends c8f6cea0a7 (v3.0.1.9128) Revamp console output of interpretive_rules() with cli styling and guideline-dependent SIR colours, make it 11 to 18 times faster with identical results, and fix counts of values that were not actually written (#259) 2026-10-13 12:27:38 +02:00
dr. M.S. (Matthijs) Berends bbfefe65ed (v3.0.1.9127) update NEWS 2026-10-13 08:44:38 +02:00
dr. M.S. (Matthijs) Berends 32fc9bd689 (v3.0.1.9126) Improve translations of combination names and antimicrobial groups in 20 languages (not en, nl, uk, fr) 2026-10-12 22:56:12 +02:00
dr. M.S. (Matthijs) Berends 04a2f0b3ac (v3.0.1.9125) Fix translations being translated again (e.g. Ticarcillinee, groupee) and untranslated parts of combination names, and let as.mo() recognise translated names in the set language, cached per language 2026-10-12 22:25:57 +02:00
dr. M.S. (Matthijs) Berends d4ba5051e7 (v3.0.1.9124) Update French CoNS name in translation test after improved French translations (#322) 2026-10-12 21:39:36 +02:00
dr. M.S. (Matthijs) Berends bf12e3abe7 (v3.0.1.9123) Add method argument to sir_combine() for resistance within a group (most_resistant), and restore the AMR 3.0.1 behaviour of count_*() and proportion_*() for multiple antimicrobials (#321) 2026-10-12 21:37:13 +02:00
dr. M.S. (Matthijs) Berends 239c5a87a8 (v3.0.1.9122) NEWS update 2026-10-12 12:55:27 +02:00
dr. M.S. (Matthijs) Berends 0293d296aa (v3.0.1.9121) styler 2026-10-12 11:42:06 +02:00
dr. M.S. (Matthijs) Berends e19eabe828 (v3.0.1.9119) update doc 2026-10-11 23:03:06 +02:00
dr. M.S. (Matthijs) Berends 36e6388868 (v3.0.1.9118) update doc 2026-10-11 22:32:15 +02:00
dr. M.S. (Matthijs) Berends 10053d582e (v3.0.1.9117) Fix static test in test-zzz.R to run without testthat (R 3.0/4.0 tinytest) 2026-10-11 22:15:43 +02:00
dr. M.S. (Matthijs) Berends 53d0704271 (v3.0.1.9116) New sir_combine() for combination therapy as one engine for antibiogram(), wisca(), count_*() and proportion_*() (#321), and make all suggested packages runtime-only with a new CI workflow without dplyr
- New sir_combine() to combine SIR results of multiple antimicrobials into one variable; antibiogram(), wisca() and the count/proportion functions now use the same engine (antibiogram() and wisca() output unchanged)
- With multiple antimicrobials, count_*() and proportion_*() now follow the documented combination therapy rules: resistance() is the proportion of failing combinations, count_all() excludes isolates with an unknown combination result, and WT/NWT/NS/NI are handled correctly
- where() is now decided at runtime instead of at installation, fixing antibiogram() and wisca() without tidyselect (e.g. CRAN binaries without dplyr)
- Imports from data.table and cli moved to .onLoad(); data.table functions are only used while it is loaded; the like() example no longer unloads data.table, which crashed R
- Static test that fails on code outside functions depending on suggested packages
- New check-without-dplyr workflow: installs AMR with all suggested packages, removes dplyr (and tidyselect), then runs all unit tests and examples against the installed package
- g.test() now returns the degrees of freedom as 'parameter', so they are printed
- Fix R CMD check NOTEs (hidden .claude folder, lost braces in inherited g.test and ggplot_pca docs)
2026-10-11 20:36:31 +02:00
dr. M.S. (Matthijs) Berends 80afedeb8c (v3.0.1.9115) Fix interpretation of capped MICs without an S category (off-scale S breakpoint) or without breakpoints in as.sir(), and correct the documented default of capped_mic_handling (#295) 2026-10-11 15:40:09 +02:00
dr. M.S. (Matthijs) Berends 9e609dae83 (v3.0.1.9114) Fix errors without cli and on R 3.0, and make the tinytest pipeline actually run the unit tests
Package:
- stop_() called cli::ansi_has_hyperlink_support() before checking that cli is available, so without cli every error became "there is no package called 'cli'"
- interpretive_rules() failed on R 3.0 for guidelines without AmpC rules (assignment to zero rows)
- Guard the ggplot2 example of wisca_plot()

CI:
- check-old: R 3.0 could not install tinytest over HTTPS, so no unit tests ran; install it with curl, and fail when tinytest is missing or any test fails
- tinytest shim: record expectations in the test file environment, support skips and errors per test_that() block, add missing testthat equivalents, source helper files
- Add R 4.0 (oldrel-6) to check-old, and oldrel-5 to check-recent
2026-10-10 14:54:15 +02:00
dr. M.S. (Matthijs) Berends f0699c6584 (v3.0.1.9113) Fix infinite loop in the plain-text message fallback (used without cli or with old cli/rlang), e.g. for wisca(parallel = TRUE) without a future plan 2026-10-10 13:27:54 +02:00
dr. M.S. (Matthijs) Berends 01ca2b98ac (v3.0.1.9112) Fix detection of non-UTF-8 input in as.ab() and add_custom_antimicrobial_synonyms() on R 4.2 and older, where enc2utf8() escapes invalid bytes 2026-10-10 12:49:13 +02:00
dr. M.S. (Matthijs) Berends 31692a26d1 (v3.0.1.9111) Let the TODO tracker fail when markers lack an issue reference, after updating #231 2026-10-10 11:47:33 +02:00
dr. M.S. (Matthijs) Berends aa462e0ad6 (v3.0.1.9110) Link all code TODO markers to issues (#317, #318, #319), and stop counting the WHONET code "XXX" in the TODO tracker 2026-10-10 11:46:17 +02:00
dr. M.S. (Matthijs) Berends 16a13ba81f (v3.0.1.9109) Fix WHONET codes SUD and ROX in clinical_breakpoints, and add sulbactam/durlobactam (#308) 2026-10-10 09:42:25 +02:00
dr. M.S. (Matthijs) Berends 6a778daeb8 (v3.0.1.9108) Fix the seed in index.Rmd, so that the WISCA output in index.md no longer changes on every build 2026-10-10 09:14:29 +02:00
dr. M.S. (Matthijs) Berends 9e05fe184b (v3.0.1.9106) Fix trade names of combinations filed under a single agent, and remove non-synonyms from antimicrobials (#315) 2026-10-09 22:25:44 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 4aafe9a676 (v3.0.1.9103) Replace dead EC Union Register URLs; URL check no longer includes closing braces
The pre-commit URL extractor captured the closing brace of \url{}, which
made the EC server redirect to the dead health.ec.europa.eu domain, after
which urlchecker::url_update() wrote that dead URL back into R/ab.R and R/av.R.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 19:53:40 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 e42237ff0d (v3.0.1.9102) Replace dead EC Union Register and CLSI M100 URLs in documentation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 19:50:21 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 e7e58f24f9 (v3.0.1.9101) Fix Aerococcus, Pasteurella and N. meningitidis interpretive rules (#290)
- Aerococcus rules now use `one_of`, so multi-species rules (breakpoints v12 onwards) apply
- Pasteurella rules filed under Neisseria meningitidis moved to their own rule
- Pasteurella rules now apply on genus level

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-04 19:46:41 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 6d54d581b2 (v3.0.1.9100) Fix unit test on wrapped warnings; taxonomy build never touches the version number
- test-data-microorganisms.R: warnings are wrapped to the console width, so the expected patterns now
  allow a line break between words (failed on GitHub Actions since v3.0.1.9097)
- reproduction_of_microorganisms_CLAUDE.md, step 4: the agent never changes the version number or date,
  the human sets them when merging

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 20:32:43 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 1a7f01bfb0 (v3.0.1.9099) Move microorganisms_known_defects.csv out of tests/ to data-raw/microorganisms_files/
- the list of known defects is development data and must not ship with the package
- tests read it from the source repository; mo_repository_root() now walks up from the working
  directory, so the tests also find the repository from an R CMD check directory inside it (GitHub Actions)
- the integrity, known-defects and sentinel tests skip when the source repository is not available
- CLAUDE.md: on local commits to main, the git hooks set the version number and date

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 19:34:07 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 6ab8ff8c33 (v3.0.1.9098) Approve name of species group B_MYCBC_AVIM-C as 'Mycobacterium avium complex'
As curated in data-raw/Species groups.xlsx since July 2023; the released v3.0.1 data still
used 'Mycobacterium avium-intracellulare complex' for the same group of organisms.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 14:16:47 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 83a4853936 (v3.0.1.9097) Never remove released taxa; link orthographic variants; registry line in NEWS
- taxonomy build: released taxa (since v2.0.0) that are missing are restored from their
  last release with their old code and last known status, and are exempt from later
  removals (decision by Matthijs S. Berends)
- exceptions are retired on purpose in data-raw/microorganisms_files/mo_code_retirements.csv
  with a reason: other organisms with the same genus name (e.g. the Graphium butterflies,
  wrongly in the Fungi until v3.0.1) and taxa whose genus is now only known in another
  domain; as.mo() translates these codes to NA with that reason
- synonyms without a current name are linked to an accepted name in the same genus that
  only differs by a Latin gender ending (e.g. Candida glabratus -> Nakaseomyces glabratus)
- placeholders such as "(unknown class)" never become records; codes of manually added
  records are matched by domain and name
- integrity rule released_taxon_missing; known defects of the data on main updated

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 14:15:08 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 d683b9e7c6 (v3.0.1.9096) MO code registry: codes never change meaning, are never guessed, and are validated
- data-raw/microorganisms_files/: registry of all MO codes of every release since v2.0.0
  (78,992 codes, built from the git tags), approved renames, and README with the rules;
  decision by Matthijs S. Berends: MO codes from before v2.0.0 are not supported
- as.mo(): codes of earlier releases are translated deterministically via the internal
  MO_RETIRED_CODES (generated from the registry); unknown codes are no longer guessed
  (previously F_TRCHP, Trichophyton in v3.0.1, became Talaromyces chlamydosporus)
- synonym_mo_to_accepted_mo(): a missing target of one source no longer overwrites a valid
  target of another source (e.g. Chaetomium abuense), and no 'renamed to itself'
- taxonomy build: codes are reused and reserved from the registry instead of the development
  data (fixes 40 codes reused in the 2026 development data), also for phylum to family;
  synonym cycles are broken; dangling 'renamed to' identifiers are removed; the build stops
  on any broken integrity rule before saving
- run_microorganisms_build.R: runs the build in chunks at its checkpoints in one R process,
  with progress logging and resuming from any checkpoint; prompt updated accordingly
- tests: shared integrity rules (helper-microorganisms.R) used by build and testthat, registry
  tests over all codes, sentinel organisms, regression tests; current defects of the data on
  main are listed in microorganisms_known_defects.csv until the next rebuild

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 11:45:25 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 ca5fa333ca (v3.0.1.9095) Taxonomy build: fix root causes of missing and misclassified taxa, add unattended run prompt
Review of reproduction_of_microorganisms.R against the 2026 intermediates:
- genus homonyms: overrides, LPSN/MycoBank first, status within LPSN/MycoBank,
  move misplaced protists, remove true homonyms (Necator, Capillaria, Graphium)
- keep clinically relevant names that are not validly published (Tropheryma)
- one set of relevant genera for all filters; 30 genera added to MO_RELEVANT_GENERA
- MycoBank classification parsed from all columns; empty values never overwrite
- GBIF synonyms in another genus get the lineage of their own genus
- prevalence no longer copied from genus; current names inherit from synonyms
- inferred records follow the relevance filters (no more unrelated lichens)
- ASCII names before deduplication (12 duplicate full names in 2026)
- MO codes: robust code parsing, reserved old codes, single allocator,
  domain column used directly (2026 rename would now fail)
- name clean-up applied to taxonomy before MO codes, BacDive rows filled
- unattended running: review() instead of View(), CSV export of reviews,
  LPSN cache and retries, stops when raw source files are missing
- reproduction_of_microorganisms_CLAUDE.md: prompt for an unattended run with
  findings report and checklist for human review in the PR

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 09:06:27 +02:00
dr. M.S. (Matthijs) BerendsandClaude Opus 5.5 b264f175f4 (v3.0.1.9094) Taxonomy build: resolve cross-domain genus homonyms by status and source (#309)
Genus resolution now prefers LPSN/MycoBank over GBIF, then accepted over
synonym, then source, then rank, and only then domain. Losing LPSN/MycoBank
homonyms are removed instead of moved into another domain. Adds integrity
checks that LPSN records stay prokaryotic and MycoBank records stay fungal.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 08:08:46 +02:00
dr. M.S. (Matthijs) Berends aebad2ae47 (v3.0.1.9091) unit test 2026-09-08 15:02:07 +02:00
dr. M.S. (Matthijs) Berends 3f50d6b6c3 (v3.0.1.9090) unit test 2026-09-04 19:47:30 +02:00
dr. M.S. (Matthijs) Berends 177e83aaf8 (v3.0.1.9089) Remove old expert rules that conflict with expected resistant phenotypes 2026-09-03 15:53:29 +02:00
dr. M.S. (Matthijs) Berends bbdd3a92e2 (v3.0.1.9088) add version number to intrinsic_resistant 2026-09-03 12:14:25 +02:00
dr. M.S. (Matthijs) Berends bd9244206d (v3.0.1.9086) new eucast update flow 2026-08-13 11:12:12 +02:00
dr. M.S. (Matthijs) Berends 9237bfbc19 (v3.0.1.9084) Fix breakpoint infer rules 2026-07-09 17:14:59 +02:00
dr. M.S. (Matthijs) Berends 5f6372342e (v3.0.1.9075) another go 2026-06-26 12:06:12 +02:00
dr. M.S. (Matthijs) Berends 3c17679382 (v3.0.1.9074) You go girl 2026-06-26 11:58:38 +02:00
dr. M.S. (Matthijs) Berends 4ca7fdf3d4 (v3.0.1.9073) yet another go 2026-06-26 11:51:08 +02:00
dr. M.S. (Matthijs) Berends 6edae2037a (v3.0.1.9072) fix py again 2026-06-26 11:47:11 +02:00
dr. M.S. (Matthijs) Berends 61e1fbf1e0 (v3.0.1.9071) fix python wrapper 2026-06-26 11:35:30 +02:00
dr. M.S. (Matthijs) Berends 637ada920b (v3.0.1.9070) Fix #293, update EUCAST rules for PEF 2026-06-26 08:56:59 +02:00
dr. M.S. (Matthijs) Berends 4fac683fac (v3.0.1.9069) fix Python wrapper 2026-06-24 20:27:39 +02:00
dr. M.S. (Matthijs) Berends b6c1c26a5d (v3.0.1.9068) todo tracker update 2026-06-24 20:01:25 +02:00
dr. M.S. (Matthijs) Berends 935071ae01 (v3.0.1.9067) todo tracker update 2026-06-24 19:43:02 +02:00
dr. M.S. (Matthijs) Berends a88150ca4a (v3.0.1.9066) fix documentation 2026-06-24 19:34:47 +02:00
dr. M.S. (Matthijs) Berends 39b6a250de (v3.0.1.9065) fix example isolates data 2026-06-24 18:36:47 +02:00
dr. M.S. (Matthijs) Berends bd63794136 (v3.0.1.9064) Documentation updates 2026-06-24 18:32:08 +02:00
dr. M.S. (Matthijs) Berends c7b17e5833 (v3.0.1.9063) fix old R version 2026-06-24 10:22:56 +02:00
dr. M.S. (Matthijs) Berends ab38fb911d (v3.0.1.9062) Fix older R versions 2026-06-24 10:19:15 +02:00
dr. M.S. (Matthijs) Berends 0c1709c999 (v3.0.1.9061) WISCA refix 2026-06-23 19:43:54 +02:00
dr. M.S. (Matthijs) Berends fd90b2c250 (v3.0.1.9060) WISCA fix 2026-06-23 19:27:40 +02:00