pub use crate::correlation::CorrelationExt;
pub use crate::deviation::DeviationExt;
pub use crate::entropy::EntropyExt;
pub use crate::histogram::HistogramExt;
pub use crate::maybe_nan::{MaybeNan, MaybeNanExt};
pub use crate::quantile::{interpolate, Quantile1dExt, QuantileExt};
pub use crate::sort::Sort1dExt;
pub use crate::summary_statistics::SummaryStatisticsExt;
#[cfg(test)]
#[macro_use]
extern crate approx;
#[macro_use]
mod multi_input_error_macros {
macro_rules! return_err_if_empty {
($arr:expr) => {
if $arr.len() == 0 {
return Err(MultiInputError::EmptyInput);
}
};
}
macro_rules! return_err_unless_same_shape {
($arr_a:expr, $arr_b:expr) => {
use crate::errors::{MultiInputError, ShapeMismatch};
if $arr_a.shape() != $arr_b.shape() {
return Err(MultiInputError::ShapeMismatch(ShapeMismatch {
first_shape: $arr_a.shape().to_vec(),
second_shape: $arr_b.shape().to_vec(),
})
.into());
}
};
}
}
#[macro_use]
mod private {
pub struct PrivateMarker;
macro_rules! private_decl {
() => {
fn __private__(&self, _: crate::private::PrivateMarker);
};
}
macro_rules! private_impl {
() => {
fn __private__(&self, _: crate::private::PrivateMarker) {}
};
}
}
mod correlation;
mod deviation;
mod entropy;
pub mod errors;
pub mod histogram;
mod maybe_nan;
mod quantile;
mod sort;
mod summary_statistics;