We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
QueryInterval.optimizeIntervals does not merge adjacent intervals as I would have expected.
QueryInterval.optimizeIntervals
Here is test code to demonstrate the issue:
@Test public void testOptimizeIntervals() throws Exception { QueryInterval[] intervals = new QueryInterval[] { new QueryInterval(0, 1519, 1520), new QueryInterval(0, 1521, 1525) }; QueryInterval[] expected = new QueryInterval[] { new QueryInterval(0, 1519, 1525), }; final QueryInterval[] got = QueryInterval.optimizeIntervals(intervals); Assert.assertEquals(expected, got); }
It fails because got still contains the two initial intervals, even though they touch.
got
I tried using htsjdk 2.10.1, java 8 and Linux.
Compile and run the test code above. Observe it fail.
I expect abutting intervals to be merged.
Overlapping intervals are merged, but abutting ones are not.
The text was updated successfully, but these errors were encountered:
fixed by #979
Sorry, something went wrong.
No branches or pull requests
Subject of the issue
QueryInterval.optimizeIntervals
does not merge adjacent intervals as I would have expected.Here is test code to demonstrate the issue:
It fails because
got
still contains the two initial intervals, even though they touch.Your environment
I tried using htsjdk 2.10.1, java 8 and Linux.
Steps to reproduce
Compile and run the test code above. Observe it fail.
Expected behaviour
I expect abutting intervals to be merged.
Actual behaviour
Overlapping intervals are merged, but abutting ones are not.
The text was updated successfully, but these errors were encountered: