lose: Drop empty variables

Description Usage Arguments Author(s) See Also Examples

Description

Convert an mvp object which is a pure constant into a scalar whose value is the coefficient of the empty term.

A few functions in the package (currently subs(), subsy()) take a lose argument that behaves much like the drop argument in base extraction.

Usage

1
2
## S3 method for class 'mvp'
lose(x)

Arguments

x

Object of class mvp

Author(s)

Robin K. S. Hankin

See Also

subs

Examples

1
2
3
4
5
m1 <- as.mvp("1+bish +bash^2 + bosh^3")
m2 <- as.mvp("bish +bash^2 + bosh^3")

m1-m2         # an mvp object
lose(m1-m2)   # numeric

mvp documentation built on Jan. 13, 2022, 1:07 a.m.