docs: def select_only_revertant_mutations(bpdf, snv=None, ins=None, dlt=None):
      """
      Selects only mutations that revert the given mutations in a single event.
      """
      if sum([bool(snv), bool(ins), bool(dlt)]) != 1:
          raise(Exception("Should be either snv, ins or del".format(snv)))
  
      if snv:
          if snv not in ["A", "C", "G", "T"]:
              raise(Exception("snv {} should be A, C, G or T".format(snv)))
          return bpdf[(bpdf.most_common_al == snv) & (bpdf.most_common_al_count == bpdf.most_common_count)]
      elif bool(ins):
          return \
              bpdf[((bpdf.most_common_indel.apply(lambda x: len(x) + len(ins) % 3 if x else None) == 0) &
                    (bpdf.most_common_indel_type == "+") & (bpdf.most_common_count == bpdf.most_common_indel_count)) |
                   ((bpdf.most_common_indel.apply(lambda x: len(ins) - len(x) % 3 if x else None) == 0) &
                    (bpdf.most_common_indel_type == "-") & (bpdf.most_common_count == bpdf.most_common_indel_count))]
      elif bool(dlt):
          return \
              bpdf[((bpdf.most_common_indel.apply(lambda x: len(x) - len(dlt) % 3 if x else None) == 0) &
                    (bpdf.most_common_indel_type == "+") & (bpdf.most_common_count == bpdf.most_common_indel_count)) |
                   ((bpdf.most_common_indel.apply(lambda x: -len(dlt) - len(x) % 3 if x else None) == 0) &
                    (bpdf.most_common_indel_type == "-") & (bpdf.most_common_count == bpdf.most_common_indel_count))]
      else:
          # should never happen
          raise(Exception("No mutation given?"))