From 1401606344449f875ee6037c4b061bd6231fac9e Mon Sep 17 00:00:00 2001 From: asivache Date: Fri, 10 Jul 2009 17:58:11 +0000 Subject: [PATCH] move warning about strictly adjacent intervals in a contig from 'remap' to 'read', so it is issued only once git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@1218 348d0f76-0448-11de-a6fe-93d51630548a --- .../sting/playground/utils/GenomicMap.java | 22 ++++++++++--------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/java/src/org/broadinstitute/sting/playground/utils/GenomicMap.java b/java/src/org/broadinstitute/sting/playground/utils/GenomicMap.java index efbb067e1..46ef74be5 100644 --- a/java/src/org/broadinstitute/sting/playground/utils/GenomicMap.java +++ b/java/src/org/broadinstitute/sting/playground/utils/GenomicMap.java @@ -146,7 +146,13 @@ public class GenomicMap implements Iterable 0 && + segments.get(segments.size()-1).getStop()+1 == newSegment.getStart() && + segments.get(segments.size()-1).getContigIndex() == newSegment.getContigIndex()) + System.out.println("WARNING: strictly adjacent segments found in custom contig "+name); + + segments.add(newSegment); p1 = p2+1; // set p1 after the comma while ( p1 < line.length() && Character.isWhitespace(line.charAt(p1))) p1++; // skip whitespaces @@ -183,8 +189,8 @@ public class GenomicMap implements Iterable currStop + 1 ) { + // add "deletion" w/respect to the master ref over the region between adjacent segments + // (and do not add anything if segments are strictly adjacent, i.e. refPos == currStop+1): newCigar.add(new CigarElement((int)(refPos-currStop-1),CigarOperator.D)); } currStop = gl.getStop();