Contents
diagnostics
Access an object's diagnostics
Reads and writes the quality and coverage reports an operation emitted alongside its value. A
bare value carries them as an attribute; a PolyGeniusAssociation or
PolyGeniusEvaluation carries them in $diagnostics.
diagnostics(x)returns every entry,diagnostics(x, field)one of them.diagnostics(x) <- valuereplaces them all,diagnostics(x, field) <- valuesets or removes one, leaving the other entries alone.
Usage
diagnostics(x, field = NULL, ...)
diagnostics(x, field = NULL) <- valueDefault S3 method:
diagnostics(x, field = NULL, ...)Default S3 method:
diagnostics(x, field = NULL) <- valueS3 method for class 'PolyGeniusResult'
diagnostics(x, field = NULL, ...)S3 method for class 'PolyGeniusResult'
diagnostics(x, field = NULL) <- valueArguments
| Argument | Description |
|---|---|
x | An R object able to carry attributes, or a PolyGeniusResult. |
field | Entry name, default NULL. A single non-empty string; NULL addresses every entry. |
... | Unused. Present for S3 method compatibility. |
value | A named list of diagnostics, or NULL to drop them. With a field, the value stored as that entry, or NULL to remove it. |
Value
- Getter: a named list of every entry, the one named by
field, orNULLwhen the set or the entry is absent. - Setter:
xwith the diagnostics updated.
Examples
x <- list(a = 1)
diagnostics(x) <- list(metric.flags = data.frame(metric = "auc", flag = "ok"))
diagnostics(x, "metric.flags")See Also
provenance(), artifacts(), PolyGeniusResult
Other result-objects:
PolyGeniusAssociation(),
PolyGeniusEvaluation(),
PolyGeniusResult(),
artifacts(),
federate(),
provenance()