Validate PEcAn events JSON against schema v0.1.0
Source:R/validate_events.R
validate_events_json.RdValidates a PEcAn events JSON file (single-site object or an array of site objects) against the bundled JSON Schema using the AJV engine.
Arguments
- events_json
character. Path to the JSON file to validate.
- schema_version
character. Version of the PEcAn events schema to validate against.
- verbose
logical. When `TRUE`, include detailed AJV messages on error.
- max_errs
integer. Print only this many validation errors. To see the rest, use the `errors` attribute of the return value.
Value
Logical TRUE if valid. If invalid, FALSE with an attribute "errors" containing a dataframe of reported problems. NA if validator unavailable.