[Rd] cumsum method in Math group

Edzer Pebesma edzer.pebesma at uni-muenster.de
Thu Jun 9 10:13:55 CEST 2016


When running

a = runif(10)
class(a) = "foo"
Math.foo = function(x, ...) {
    NextMethod(.Generic)
}
signif(a, 3)
cumsum(a)


I don't understand why cumsum strips the class, but signif does not.
Both claim in the documentation that "These are generic functions:
methods can be defined for them individually or via the ‘Math’ group
generic."

-- 
Edzer Pebesma
Institute for Geoinformatics  (ifgi),  University of Münster
Heisenbergstraße 2, 48149 Münster, Germany; +49 251 83 33081
Journal of Statistical Software:   http://www.jstatsoft.org/
Computers & Geosciences:   http://elsevier.com/locate/cageo/
Spatial Statistics Society http://www.spatialstatistics.info

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: OpenPGP digital signature
URL: <https://stat.ethz.ch/pipermail/r-devel/attachments/20160609/e233e21f/attachment.bin>


More information about the R-devel mailing list