Skip to content

filters

Filters

Filters(pql_filters=None, saola_connector=None)

Bases: ImmutableObject

Collection of filters to filter Series or DataFrame.

Parameters:

  • pql_filters (Optional[Sequence[FilterLike]]) –

    PQL filters to use.

  • saola_connector (Optional[SaolaConnector]) –

    Saola connector used to export data.

pql_filters property

pql_filters: List[PQLFilter]

Returns list of pql filters.

saola_connector property

saola_connector: SaolaConnector

Returns saola connector of series.

filter_expression property

filter_expression: Optional[str]

Returns filter expression for given filters.

object_str staticmethod

object_str(class_name, properties)

Returns string representation of object with given class name and properties.

Parameters:

  • class_name (str) –

    Name of object class.

  • properties (OrderedDict[str, Any]) –

    Properties to include.

Returns:

  • str

    String representation.

shorten_string staticmethod

shorten_string(string, max_length=None)

Shortens string to have maximum of max_length characters.

add

add(filter_)

Adds filter to pql filters.

copy

copy(pql_filters=None, saola_connector=None)

Returns copy of given filters.