def setAlignmentMethod(method):
    """Set pairwise alignment method (global or local)."""
    if method in ('local', 'global'):
        global ALIGNMENT_METHOD
        ALIGNMENT_METHOD = method
    else:
        raise ValueError('method must be "local" or "global"')
