Number of nucleotide bases to either side of the specified locus to provide regions for. For example, if halfWindowSize=5, and our currentLocus=100, then currentRegions will include regions that map to anywhere between 95 and 105, inclusive. Set to 0 to consider only regions that overlap the exact locus being considered, with no surrounding window.
Iterator of regions, sorted by the aligned start locus.
The locus currently under consideration.
The regions that overlap the window surrounding currentLocus.
Number of nucleotide bases to either side of the specified locus to provide regions for.
Number of nucleotide bases to either side of the specified locus to provide regions for. For example, if halfWindowSize=5, and our currentLocus=100, then currentRegions will include regions that map to anywhere between 95 and 105, inclusive. Set to 0 to consider only regions that overlap the exact locus being considered, with no surrounding window.
The new regions that were added to currentRegions as a result of the most recent call to setCurrentLocus.
Find the next locus for which calling setCurrentLocus(locus) would result in a non-empty set of regions in currentRegions.
Find the next locus for which calling setCurrentLocus(locus) would result in a non-empty set of regions in currentRegions.
Some(locus) if such a locus exists, otherwise None
Iterator of regions, sorted by the aligned start locus.
Advance to the specified locus, which must be greater than the current locus.
Advance to the specified locus, which must be greater than the current locus. After calling this, the currentRegions method will give the overlapping regions at the new locus.
Locus to advance to.
The *new regions* that were added as a result of this call. Note that this is not the full set of regions in the window: you must examine currentRegions for that.
Suppose we have a set of loci on a given contig and some objects that are mapped to that contig, and at each locus we want to look at the regions that overlap a window of a certain number of bases surrounding that locus. This class implements this "sliding window" functionality.
After instantiating this class, call setCurrentLocus repeatedly for each locus being considered. After calling this method, the currentRegions property will contain the objects that overlap the current locus. s To enable an efficient implementation, we require that both the sequence of loci to be considered and the iterator of objects are sorted.
Number of nucleotide bases to either side of the specified locus to provide regions for. For example, if halfWindowSize=5, and our currentLocus=100, then currentRegions will include regions that map to anywhere between 95 and 105, inclusive. Set to 0 to consider only regions that overlap the exact locus being considered, with no surrounding window.
Iterator of regions, sorted by the aligned start locus.