
Choose the best diagnostic engine for a single pedon
Source:R/engine-selection-v0965.R
pick_engine.RdPer-pedon heuristic: returns "aqp" if the pedon's horizon
table has the morphological richness that makes aqp's canonical
NRCS dispatch reliable, otherwise returns "soilkey" (the
more permissive hand-coded path).
Arguments
- pedon
A
PedonRecord.- min_score
Integer (1-5). Minimum completeness score for
"aqp"engine to fire (default 3).
Heuristic
We score each pedon on a 0-5 morphology-completeness scale; aqp
fires when score \>= min_score (default 3). The five
axes:
Designation present (any layer has a non-blank
designation, e.g. "A1", "Bt2", "Bw").Texture quantitative (any layer has both
clay_pctandsand_pctpopulated).Munsell complete (any layer has all three of
munsell_hue_moist,munsell_value_moist,munsell_chroma_moistpopulated).Structure recorded (any layer has a non-blank
structure_grade).Clay films / argic evidence (any layer has a non-blank
clay_films_amountor designation pattern matchingBt).
Why this matters
On BDsolos RJ (data-rich), the heuristic recommends aqp for
~99
canonical thresholds). On LUCAS topsoil-only (data-sparse), it
recommends aqp for ~0
clay-films / designation axes are unfilled. Calling
classify_*(pedon) routed through the heuristic gives the
correct engine per pedon, recovering both the BDsolos RJ lift
AND the LUCAS robustness.