pybedtools.bedtool.BedTool.absolute_distance

BedTool.absolute_distance(other, closest_kwargs=None, use_midpoints=False)[source]

Returns an iterator of the absolute distances between features in self and other.

If use_midpoints is True, then only use the midpoints of features (which will return values where features are overlapping). Otherwise, when features overlap the value will always be zero.

closest_kwargs are passed to self.closest(); either d or ‘D` are required in order to get back distance values (d=True is default)