Downloads the weighted long catch table, runs every validator in
R/validation-functions.R, and publishes the validated landings and the
per-submission flags. Outlier identification uses the median absolute
deviation by default.
Usage
validate_landings(log_threshold = logger::DEBUG)Arguments
- log_threshold
The (standard Apache logj4) log level used as a threshold for the logging infrastructure. See logger::log_levels for more details
Outputs
<...>_validated_long__*.parquet— one row per (submission, catch, length bin) under the standard column names. As in Kenya, Mozambique and Zanzibar, it holds only the submissions with no flag or a reviewer's approval, never one a reviewer rejected.<surveys.landings.validation.flags.file_prefix>__*.parquet— a versioned snapshot of the flags.coasts::mdb_collection_push()replaces a collection wholesale, so this is the only history of what was flagged when.
Flags sink
Flags go to the shared cross-country validation database, one
surveys_flags-<asset_id> collection per live form plus the matching
enumerators_stats-<asset_id>; v1 is frozen and gets neither.
Reviewers' decisions are read first, from the collection the Peskas
Management Platform writes to and from KoBoToolbox (with
coasts::review_decisions()), so they are kept rather than overwritten.
