periodic_range_filter
PeriodicRangeFilter
Bases: DataFilter
A data filter to constrain the data to a range. This range can be defined in a number of ways: - Using a period and an upper and lower bound: range of [lower_bound, upper_bound] - Using an upper and lower bound: range of [lower_bound, upper_bound], period = upper_bound - lower_bound - using a period and an upper bound: range of ]-inf, upper_bound] - using a period and a lower bound: range of [lower_bound, inf[ - using only a period: range of [0, period]
lower_bound = lower_bound
instance-attribute
period = period
instance-attribute
upper_bound = upper_bound
instance-attribute
__init__(period=None, lower_bound=None, upper_bound=None)
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
period |
float | NoneType
|
The period of the scalar data. Defaults to None. |
None
|
lower_bound |
float | NoneType
|
The lower bound of the selected range (inclusive). Defaults to None. |
None
|
upper_bound |
float | NoneType
|
The upper bound of the selected range (inclusive). Defaults to None. |
None
|
apply(scalars)
Check if enough arguments are passed to use this method/NoneType and then limit the scalar range by using a method based on the arguments passed.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
scalars |
ndarray
|
array of scalars |
required |
Returns:
| Name | Type | Description |
|---|---|---|
scalars |
ndarray
|
updated array of scalars |