code: def create_filter(predicate_param, predicate_factory):
    
    # NOTE: Do not inline this into create_filters above. A separate function is necessary
    # in order to capture the different closure on each invocation.
    modifier, param = _extract_modifier(predicate_param)
    predicates = [predicate_factory(p) for p in param.split(',')]
    def filt(x):
      return modifier(any(pred(x) for pred in predicates))
    return filt
docs: Create a filter function from a string parameter.
  
    :param predicate_param: Create a filter for this param string. Each string is a
                            comma-separated list of arguments to the predicate_factory.
                            If the entire comma-separated list is prefixed by a '-' then the
                            sense of the resulting filter is inverted.
    :param predicate_factory: A function that takes a parameter and returns a predicate, i.e., a
                              function that takes a single parameter (of whatever type the filter
                              operates on) and returns a boolean.
    :return: A filter function of one argument that is the logical OR of the predicates for each of
             the comma-separated arguments. If the comma-separated list was prefixed by a '-',
             the sense of the filter is inverted.