code: def variants_in_coords(nucmer_matches, vcf_file):
          '''nucmer_matches = made by assembly_compare.assembly_match_coords().
             Returns number of variants that lie in nucmer_matches'''
          found_variants = {}
          f = pyfastaq.utils.open_file_read(vcf_file)
          for line in f:
              if line.startswith('#'):
                  continue
  
              data = line.rstrip().split('\t')
              scaff = data[0]
  
              if scaff in nucmer_matches:
                  position = int(data[1]) - 1
                  i = pyfastaq.intervals.Interval(position, position)
                  intersects = len([x for x in nucmer_matches[scaff] if x.intersects(i)]) > 0
                  if intersects:
                      if scaff not in found_variants:
                          found_variants[scaff] = set()
                      found_variants[scaff].add(position)
  
          pyfastaq.utils.close(f)
          return found_variantf variants_in_coords(nucmer_matches, vcf_file):
          '''nucmer_matches = made by assembly_compare.assembly_match_coords().
             Returns number of variants that lie in nucmer_matches'''
          found_variants = {}
          f = pyfastaq.utils.open_file_read(vcf_file)
          for line in f:
              if line.startswith('#'):
                  continue
  
              data = line.rstrip().split('\t')
              scaff = data[0]
  
              if scaff in nucmer_matches:
                  position = int(data[1]) - 1
                  i = pyfastaq.intervals.Interval(position, position)
                  intersects = len([x for x in nucmer_matches[scaff] if x.intersects(i)]) > 0
                  if intersects:
                      if scaff not in found_variants:
                          found_variants[scaff] = set()
                      found_variants[scaff].add(position)
  
          pyfastaq.utils.close(f)
          return found_variants
docs: nucmer_matches = made by assembly_compare.assembly_match_coords().
             Returns number of variants that lie in nucmer_matches