MCPcopy Create free account
hub / github.com/numpy/numpy / __sub__

Method __sub__

numpy/core/tests/test_function_base.py:20–22  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

18 __radd__ = __add__
19
20 def __sub__(self, x):
21 assert_(isinstance(x, PhysicalQuantity))
22 return PhysicalQuantity(float(self) - float(x))
23
24 def __rsub__(self, x):
25 assert_(isinstance(x, PhysicalQuantity))

Callers

nothing calls this directly

Calls 2

assert_Function · 0.90
PhysicalQuantityClass · 0.85

Tested by

no test coverage detected