pub struct ExponentialDistribution { /* private fields */ }
Expand description
Exponential distribution with an optional shift. The probability density function (PDF) is defined as follows:
For a positive tail (when positive_tail
is true
):
f(x; λ, offset) = λ exp(-λ (x - offset)) for x ≥ offset
For a negative tail (when positive_tail
is false
):
f(x; λ, offset) = λ exp(-λ (offset - x)) for x ≤ offset
In both cases, the PDF is 0
outside the specified domain.
For more information, see:
Implementations§
Source§impl ExponentialDistribution
impl ExponentialDistribution
pub fn data_type(&self) -> DataType
pub fn rate(&self) -> &ScalarValue
pub fn offset(&self) -> &ScalarValue
pub fn positive_tail(&self) -> bool
pub fn mean(&self) -> Result<ScalarValue, DataFusionError>
pub fn median(&self) -> Result<ScalarValue, DataFusionError>
pub fn variance(&self) -> Result<ScalarValue, DataFusionError>
pub fn range(&self) -> Result<Interval, DataFusionError>
Trait Implementations§
Source§impl Clone for ExponentialDistribution
impl Clone for ExponentialDistribution
Source§fn clone(&self) -> ExponentialDistribution
fn clone(&self) -> ExponentialDistribution
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ExponentialDistribution
impl Debug for ExponentialDistribution
Source§impl PartialEq for ExponentialDistribution
impl PartialEq for ExponentialDistribution
impl StructuralPartialEq for ExponentialDistribution
Auto Trait Implementations§
impl Freeze for ExponentialDistribution
impl !RefUnwindSafe for ExponentialDistribution
impl Send for ExponentialDistribution
impl Sync for ExponentialDistribution
impl Unpin for ExponentialDistribution
impl !UnwindSafe for ExponentialDistribution
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more