:py:mod:`rhino_health.lib.metrics.filter_variable` ================================================== .. py:module:: rhino_health.lib.metrics.filter_variable Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: rhino_health.lib.metrics.filter_variable.FilterType rhino_health.lib.metrics.filter_variable.FilterRangePair rhino_health.lib.metrics.filter_variable.FilterBetweenRange rhino_health.lib.metrics.filter_variable.FilterVariable Attributes ~~~~~~~~~~ .. autoapisummary:: rhino_health.lib.metrics.filter_variable.FilterVariableTypeOrColumnName .. py:class:: FilterType Bases: :py:obj:`enum.Enum` Enum/Constants to specify the type of filtering to perform. Supported filtering methods are listed below .. !! processed by numpydoc !! .. py:attribute:: EQUAL :value: '=' .. py:attribute:: IN :value: 'in' Filter data .. rubric:: Notes filter_value should be a list which can be checked against using `pd.Series.isin() `_ .. !! processed by numpydoc !! .. py:attribute:: NOT_IN :value: 'not in' Filter data .. rubric:: Notes filter_value should be a list which can be checked against using `pd.Series.isin() `_ .. !! processed by numpydoc !! .. py:attribute:: GREATER_THAN :value: '>' .. py:attribute:: LESS_THAN :value: '<' .. py:attribute:: GREATER_THAN_EQUAL :value: '>=' .. py:attribute:: LESS_THAN_EQUAL :value: '<=' .. py:attribute:: BETWEEN :value: 'between' .. py:class:: FilterRangePair(**data: Any) Bases: :py:obj:`pydantic.BaseModel` Specifies the upper or lower range to check against when using ranges instead of a fixed number .. !! processed by numpydoc !! .. py:attribute:: filter_value :type: Any .. py:attribute:: filter_type :type: FilterType .. warning:: FilterType.BETWEEN and FilterType.IN are not supported in FilterRangePair .. !! processed by numpydoc !! .. py:class:: FilterBetweenRange(**data: Any) Bases: :py:obj:`pydantic.BaseModel` Specifies the upper and lower range to check against when using ranges instead of a fixed number .. !! processed by numpydoc !! .. py:attribute:: lower :type: FilterRangePair .. py:attribute:: upper :type: FilterRangePair .. py:class:: FilterVariable(**data: Any) Bases: :py:obj:`pydantic.BaseModel` Defines filter logic to compare data against. .. !! processed by numpydoc !! .. py:attribute:: data_column :type: str The column in the remote Dataset df to get data from after filtering .. !! processed by numpydoc !! .. py:attribute:: filter_column :type: str The column in the remote Dataset df to check against .. !! processed by numpydoc !! .. py:attribute:: filter_value :type: Union[Any, FilterBetweenRange] The value to match against or a FilterBetweenRange if filter_type is FilterType.BETWEEN .. !! processed by numpydoc !! .. py:attribute:: filter_type :type: Optional[FilterType] The type of filtering to perform. Defaults to FilterType.EQUAL .. !! processed by numpydoc !! .. py:data:: FilterVariableTypeOrColumnName Either a string or a FilterVariable. Union[str, FilterVariable] .. seealso:: :obj:`rhino_health.lib.metrics.filter_variable.FilterVariable` .. .. !! processed by numpydoc !!