Used inside vars() to attach documentation to a variable. Units are
stored and displayed; unit algebra (automatic consistency checking
inside equations) is on the roadmap.
Arguments
- label
Human-readable description, e.g.
"Output gap"(or numeric data, which is passed tostats::var()).- unit
Unit of measurement, e.g.
"pp","pct pa".- ...
Passed to
stats::var()in the delegation case.
Value
An object of class qpm_var, or the result of stats::var().
Details
When given numeric data instead of a character label, var()
delegates to stats::var(), so attaching qpmR does not break variance
computations.