MCPcopy Create free account
hub / github.com/chaimleib/intervaltree / span

Method span

intervaltree/intervaltree.py:970–978  ·  view source on GitHub ↗

Returns the length of the minimum-spanning Interval that encloses all the members of this IntervalTree. If the tree is empty, return 0.

(self)

Source from the content-addressed store, hash-verified

968 return Interval(self.begin(), self.end())
969
970 def span(self):
971 """
972 Returns the length of the minimum-spanning Interval that
973 encloses all the members of this IntervalTree. If the tree
974 is empty, return 0.
975 """
976 if not self:
977 return 0
978 return self.end() - self.begin()
979
980 def print_structure(self, tostring=False):
981 """

Callers 1

test_spanFunction · 0.95

Calls 2

endMethod · 0.95
beginMethod · 0.95

Tested by 1

test_spanFunction · 0.76