
Iterate a flat taxa list and evaluate tests in canonical order
Source:R/rule-engine.R
run_taxa_list.RdInternal iterator extracted from run_taxonomic_key so
nested categorical levels (subordens, grandes grupos, subgrupos,
familias) can be iterated directly, without going through the
rules[[level_key]] indirection that only makes sense at the
top level.
Arguments
- pedon
A
PedonRecord.- taxa
A list of taxon entries; each entry must have
code,name, andtestsfields, wheretestsis a block parseable byevaluate_rsg_tests.
Value
A list with assigned (the entry of the assigned taxon,
or NULL when taxa was empty) and trace.
Details
Behavioural note: when taxa is empty or NULL, returns
list(assigned = NULL, trace = list()) – a sub-level lookup
with no canonical entries is non-fatal. The top-level
run_taxonomic_key keeps the stricter "missing list is
an error" semantics by guarding before calling this helper.