inst/Examples/trackEqualMethods.R

setMethod("==", c("track", "track"),
          function(e1, e2) {
              e1@x == e2@x &
                e1@y == e2@y
          })

setMethod("!=", c("track", "track"),
          function(e1, e2) {
              e1@x != e2@x |
                e1@y != e2@y
          })

Try the SoDA package in your browser

Any scripts or data that you put into this service are public.

SoDA documentation built on Oct. 28, 2020, 9:07 a.m.