RobinHankin / spray

sparse arrays and fast multivariate polynomials
https://robinhankin.github.io/spray/
2 stars 2 forks source link

loads of functions should be generic #22

Open RobinHankin opened 3 years ago

RobinHankin commented 3 years ago

if you load the mvp package and then the spray package, loads of functions get masked. e.g. in the mvp package, sourcing inst/coercion.R gives:

> source("coercion.R")   # low-level functions, e.g. as.mvp()

Attaching package: ‘spray’

The following objects are masked from ‘package:mvp’:

    aderiv, coeffs, coeffs<-, constant, constant<-, homog, is.zero,
    knight, linear, nterms, ooom, product, subs, xyz

The following objects are masked from ‘package:base’:

    pmax, pmin

It would be good to make at least some of the masked functions generic.

RobinHankin commented 3 years ago

some of these are already generic in the spray package but not the mvp package, where I will raise a new issue. But it would be good to genericalize is.zero() and possibly subs().