Example #1
0
def phaser_stages13(debug=False, print_times=False):
    return new_phaser_chain([
        prepare_phaser(),
        trivial_phaser(),
        family_phaser(),
        family_child_comparison_phaser(),
    ],
                            debug=debug,
                            print_times=print_times)
Example #2
0
def nuclear_family_phaser(debug=False, print_times=False):
    return new_phaser_chain([
        prepare_phaser(),
        trivial_phaser(),
        family_phaser(),
        family_child_comparison_phaser(),
        family_sib_comparison_phaser(),
    ],
                            debug=debug,
                            print_times=print_times)
Example #3
0
def __build_phaser(options):
    '''Bulid and return the phasing processing chain by options - factory method.'''
    if options.stage == 0:
        # 07-DEC-12: disabling stage 4 (family_sib_comparison_phaser) since it degrades phasing & imputation
        chain = [
            prepare_phaser(),
            trivial_phaser(),
            family_phaser(),
            family_child_comparison_phaser(),
            phase_distant.family_sib_comparison_phaser(),
            phase_distant.distant_phaser()
        ]
    elif options.stage == 1:
        chain = [prepare_phaser(), trivial_phaser()]
    elif options.stage == 2:
        chain = [family_phaser()]
    elif options.stage == 3:
        chain = [family_child_comparison_phaser()]
    elif options.stage == 4:
        chain = [phase_distant.family_sib_comparison_phaser()]
    elif options.stage == 5:
        chain = [phase_distant.distant_phaser()]
    return chain
Example #4
0
def prepare_and_trivial_phaser(debug=False, print_times=False):
    return new_phaser_chain(
        [prepare_phaser(), trivial_phaser()],
        debug=debug,
        print_times=print_times)
Example #5
0
def __build_pre_phaser(options):
    #    if options.stage != 0:
    #        return []
    return [prepare_phaser()]
Example #6
0
 def setUp(self):
     '''Load test data and expected results.'''
     unittest.TestCase.setUp(self)
     # The way to load a pedigree in conjunction with a genotype set is to recode
     # its sample IDs to consecutive for easier access by phasers.
     self.phaser = prepare_phaser()