code: def processBED(fh, genome_alig, window_size, window_centre,
                 mi_seqs=MissingSequenceHandler.TREAT_AS_ALL_GAPS, species=None,
                 verbose=False):
    
    mean_profile = []
    while len(mean_profile) < window_size:
      mean_profile.append(RollingMean())
  
    for e in BEDIterator(fh, verbose=verbose, scoreType=float,
                         sortedby=ITERATOR_SORTED_START):
      # figure out which interval to look at...
      transform_locus(e, window_centre, window_size)
      new_profile = conservtion_profile_pid(e, genome_alig, mi_seqs, species)
      merge_profile(mean_profile, new_profile)
    return [m.mean for m in mean_profile]
docs: Process BED file, produce profile of conservation using whole genome alig.
  
    :param fh:
    :param genome_alig:   the whole-genome alignment to use to compute
                          conservation scores
    :param window_size:   length of the profile.
    :param window_center: which part of each interval to place at the center
                          of the profile. Acceptable values are in the module
                          constant WINDOW_CENTRE_OPTIONS.
    :param miss_seqs:     how to treat sequence with no actual sequence data for
                          the column.
    :param verbose:       if True, output progress messages to stderr.
  
    :return: