pub struct ThresholdFilter {
pub min: Option<f32>,
pub max: Option<f32>,
}Expand description
Masks gates whose values fall outside a specified range.
Gates with values below min or above max are set to GateStatus::NoData.
Either bound may be None to leave that side unbounded.
§Example
ⓘ
use nexrad_process::filter::ThresholdFilter;
// Remove all reflectivity below 5 dBZ
let filter = ThresholdFilter { min: Some(5.0), max: None };
let filtered = filter.process(&field)?;Fields§
§min: Option<f32>Minimum acceptable value. Gates below this are masked.
max: Option<f32>Maximum acceptable value. Gates above this are masked.
Trait Implementations§
Source§impl SweepProcessor for ThresholdFilter
impl SweepProcessor for ThresholdFilter
Source§fn process(&self, input: &SweepField) -> Result<SweepField>
fn process(&self, input: &SweepField) -> Result<SweepField>
Process the input field, producing a new field with the same geometry.
Auto Trait Implementations§
impl Freeze for ThresholdFilter
impl RefUnwindSafe for ThresholdFilter
impl Send for ThresholdFilter
impl Sync for ThresholdFilter
impl Unpin for ThresholdFilter
impl UnsafeUnpin for ThresholdFilter
impl UnwindSafe for ThresholdFilter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more