def processBED(fh, genome_alig, window_size, window_centre,<EOL>mi_seqs=MissingSequenceHandler.TREAT_AS_ALL_GAPS, species=None,<EOL>verbose=False):
mean_profile = []<EOL>while len(mean_profile) < window_size:<EOL><INDENT>mean_profile.append(RollingMean())<EOL><DEDENT>for e in BEDIterator(fh, verbose=verbose, scoreType=float,<EOL>sortedby=ITERATOR_SORTED_START):<EOL><INDENT>transform_locus(e, window_centre, window_size)<EOL>new_profile = conservtion_profile_pid(e, genome_alig, mi_seqs, species)<EOL>merge_profile(mean_profile, new_profile)<EOL><DEDENT>return [m.mean for m in mean_profile]<EOL>
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: