Exemplo n.º 1
0
 /** Setters and Accessors for base insertion and base deletion quality scores */
 public void setBaseQualities(final byte[] quals, final EventType errorModel) {
   switch (errorModel) {
     case BASE_SUBSTITUTION:
       setBaseQualities(quals);
       break;
     case BASE_INSERTION:
       setAttribute(
           GATKSAMRecord.BQSR_BASE_INSERTION_QUALITIES,
           quals == null ? null : SAMUtils.phredToFastq(quals));
       break;
     case BASE_DELETION:
       setAttribute(
           GATKSAMRecord.BQSR_BASE_DELETION_QUALITIES,
           quals == null ? null : SAMUtils.phredToFastq(quals));
       break;
     default:
       throw new ReviewedGATKException("Unrecognized Base Recalibration type: " + errorModel);
   }
 }
Exemplo n.º 2
0
 /** @return the base deletion quality or null if read doesn't have one */
 public byte[] getExistingBaseDeletionQualities() {
   return SAMUtils.fastqToPhred(getStringAttribute(BQSR_BASE_DELETION_QUALITIES));
 }