@staticmethod<EOL><INDENT>def _select_parent(action_set):<DEDENT>
total_fitness = sum(rule.fitness for rule in action_set)<EOL>selector = random.uniform(<NUM_LIT:0>, total_fitness)<EOL>for rule in action_set:<EOL><INDENT>selector -= rule.fitness<EOL>if selector <= <NUM_LIT:0>:<EOL><INDENT>return rule<EOL><DEDENT><DEDENT>return random.choice(list(action_set))<EOL>
Select a rule from this action set, with probability
        proportionate to its fitness, to act as a parent for a new rule in
        the classifier set. Return the selected rule.