Example #1
0
  public void getISUnknownFixedIns() {
    Record pair1 = null;
    int pair1Index = -1;
    Record pair2 = null;
    int pair2Index = -1;

    for (int i = 0; i < records.size(); i++) {
      Record cur = records.get(i);
      if (cur.regular) {
        if (cur.edgeName1.equals("EDGE:111:239")
            && cur.edgeName2.equals("EDGE:72:203")
            && !cur.fwd1
            && cur.fwd2
            && cur.doesFirstOverlapWith(847025, 847475)
            && cur.doesSecondOverlapWith(1820800, 1821075)) { // pair1
          pair1 = cur;
          pair1Index = i;
          records.remove(i);
          i--;

        } else if (cur.edgeName1.equals("EDGE:111:239")
            && cur.edgeName2.equals("EDGE:72:203")
            && cur.fwd1
            && !cur.fwd2
            && cur.doesFirstOverlapWith(847700, 848050)
            && cur.doesSecondOverlapWith(1821225, 1821625)) { // pair1
          pair2 = cur;
          pair2Index = i;
          records.remove(i);
          i--;
        }
      }
    }
    if (pair1Index > -1 && pair2Index > -1) {
      System.out.println("*FIXED\n" + pair1 + "\n" + pair2 + "\n");
      // records.remove(pair1Index);
      // records.remove(pair2Index);
    } else if (pair1Index == -1 && pair2Index > -1) {
      System.out.println("*FIXED\n**MISSING**\n" + pair2 + "\n");
      // records.remove(pair2Index);
    } else if (pair1Index > -1 && pair2Index == -1) {
      System.out.println("*FIXED\n" + pair1 + "\n**MISSING**\n");
      // records.remove(pair1Index);
    } else {
      System.out.println("*FIXED\n**MISSING**\n**MISSING**\n");
    }
  }
Example #2
0
  public void getISDra3FixedIns() {
    Record pair1 = null;
    int pair1Index = -1;
    Record pair2 = null;
    int pair2Index = -1;

    for (int i = 0; i < records.size(); i++) {
      Record cur = records.get(i);
      if (cur.regular) {
        if (cur.edgeName1.equals("EDGE:137:142")
            && cur.edgeName2.equals("EDGE:184:240")
            && !cur.fwd1
            && !cur.fwd2
            && cur.doesFirstOverlapWith(253050, 253350)
            && cur.doesSecondOverlapWith(1748200, 1748500)) { // pair1
          pair1 = cur;
          pair1Index = i;
          records.remove(i);
          i--;
        } else if (cur.edgeName1.equals("EDGE:137:142")
            && cur.edgeName2.equals("EDGE:184:240")
            && cur.fwd1
            && cur.fwd2
            && cur.doesFirstOverlapWith(253650, 253950)
            && cur.doesSecondOverlapWith(1747700, 1747950)) { // pair1
          pair2 = cur;
          pair2Index = i;
          records.remove(i);
          i--;
        }
      }
    }
    if (pair1Index > -1 && pair2Index > -1) {
      System.out.println("*FIXED\n" + pair1 + "\n" + pair2 + "\n");
      // records.remove(pair1Index);
      // records.remove(pair2Index);
    } else if (pair1Index == -1 && pair2Index > -1) {
      System.out.println("*FIXED\n**MISSING**\n" + pair2 + "\n");
      // records.remove(pair2Index);
    } else if (pair1Index > -1 && pair2Index == -1) {
      System.out.println("*FIXED\n" + pair1 + "\n**MISSING**\n");
      // records.remove(pair1Index);
    } else {
      System.out.println("*FIXED\n**MISSING**\n**MISSING**\n");
    }
  }
Example #3
0
 public void removeWrapAround() {
   for (int i = 0; i < records.size(); i++) {
     Record cur = records.get(i);
     if (cur.regular) {
       if (cur.edgeName1.equals("EDGE:0:182")
           && cur.edgeName2.equals("EDGE:26:267")
           && !cur.fwd1
           && cur.fwd2
           && cur.doesFirstOverlapWith(100, 400)
           && cur.doesSecondOverlapWith(2648250, 2648550)) { // chromosome 1
         System.out.println("WRAP-AROUND FOR chromosome 1:" + records.get(i).recordLine);
         records.remove(i);
         i--;
       } else if (cur.edgeName1.equals("EDGE:26:267")
           && cur.edgeName2.equals("EDGE:129:290")
           && !cur.fwd1
           && cur.fwd2
           && cur.doesFirstOverlapWith(2648750, 2649050)
           && cur.doesSecondOverlapWith(3060550, 3060900)) { // chromosome 2
         System.out.println("WRAP-AROUND FOR chromosome 2:" + records.get(i).recordLine);
         records.remove(i);
         i--;
       } else if (cur.edgeName1.equals("EDGE:129:290")
           && cur.edgeName2.equals("EDGE:138:140")
           && !cur.fwd1
           && cur.fwd2
           && cur.doesFirstOverlapWith(3061100, 3061400)
           && cur.doesSecondOverlapWith(3238050, 3238350)) { // MP1
         System.out.println("WRAP-AROUND FOR PLASMID MP1:" + records.get(i).recordLine);
         records.remove(i);
         i--;
       } else if (cur.edgeName1.equals("EDGE:138:140")
           && cur.edgeName2.equals("EDGE:29:86")
           && !cur.fwd1
           && cur.fwd2
           && cur.doesFirstOverlapWith(3238600, 3238900)
           && cur.doesSecondOverlapWith(3283500, 3283850)) { // CP1
         System.out.println("WRAP-AROUND FOR PLASMID CP1:" + records.get(i).recordLine);
         records.remove(i);
         i--;
       }
     }
   }
   System.out.println("\n");
 }