RobustMeans.EmpiricalMeanType
mean(A::AbstractArray, Estimator::EmpiricalMean)

The usual empirical mean estimator. Nothing fancy.

RobustMeans.SmoothingKernelType
SmoothingKernel
  • h is the bandwidth parameter.
  • f is a kernel function.

Exemple of kernels are (but you can define your own)

uniform(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 1 / 2
epanechnikov(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 3 / 4 * (1 - u^2)
gaussian(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : (1 / sqrt(2 * pi)) * exp(-1 / 2 * u^2)
triangular(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : (1 - abs(u))
biweight(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 15 / 16 * (1 - u^2)^2
triweight(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 35 / 32 * (1 - u^2)^3
tricube(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 70 / 81 * (1 - abs(u)^3)^3
cosine(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : (pi / 4) * cos((pi / 2) * u)
logistic(u::T) where T<:Real = abs(u) > one(T) ? zero(T) : 1 / (exp(u) + 2 + exp(-u))
RobustMeans.LeeValMethod
LeeVal(x, w, δ; α₀ = 0.0)

Reference: Optimal Sub-Gaussian Mean Estimation in R by Lee et Valiant

RobustMeans.LeeValMethod
LeeVal(x, δ; α₀ = 0.0)

Reference: Optimal Sub-Gaussian Mean Estimation in ℝ by Lee et Valiant

RobustMeans.MinNdaMethod
MinskerNdaoud(x, k, p)

Reference: Robust and efficient mean estimation: an approach based on the properties of self-normalized sums

RobustMeans.MinNdaMethod
MinskerNdaoud(x, w, k, p)

Reference: Robust and efficient mean estimation: an approach based on the properties of self-normalized sums

RobustMeans.MoMMethod

MedianOfMean(x::AbstractArray, k::Integer)

Compute the Median of Mean with k groups (it does not permute the samples)

RobustMeans.MoMMethod

MedianOfMean(x::AbstractArray, w::AbstractWeights, k::Integer)

Compute the Median of Mean with k groups (it does not permute the samples)

RobustMeans.TrimMeanMethod
TrimmedMean(x::AbstractArray, k::Integer)

Compute the Trimmed Mean thresolding data smaller α or larger than β

RobustMeans.Z_estimatorMethod
Z_estimator(x::AbstractArray, α, ψ::Function; ini = median(x))

Implement Z estimators given a

RobustMeans.Z_estimatorMethod
Z_estimator(x::AbstractArray, w::AbstractWeights, α, ψ::Function; ini = median(x))

Implement Z estimators given a

RobustMeans.boundMethod

bound(estimator, δ, n::Int) Give the theoritical bound B such that for the estimator #TODO! correction math formula

\[\mathbb{P}( |X- \mathbb{E}(X)|/\sigma \leq B) \leq \delta\]

RobustMeans.boundMethod

" sqrt(2log(1 / δ) / n) # Multiply by a factor (1 + o(1)) where o(1) = (1+O(sqrt(log(1/δ)/n)))*(1+log(log(1/δ))/log(1/δ)) goes to zeros with (log(1/δ)/n, δ)→ (0, 0) see https://www.youtube.com/watch?v=Kr0Kl_sXsJM Q&A

RobustMeans.chunkMethod
chunk(n, k)

Divide an set {1,2,...,n} into k blocks of equal size (exept the last one if n is not a multiple of k)

Statistics.meanMethod

mean(A::AbstractArray, Estimator::MoM)

The Median of Mean estimator.

Statistics.meanMethod

mean(A::AbstractArray, Estimator::Catoni, kwargs...)

Reference: Catoni

Statistics.meanMethod
mean(A::AbstractArray, δ::Real, Estimator::EmpiricalMean)

The usual empirical mean estimator, for convenience, we authorize the extra dummy argument δ.

Statistics.meanMethod

mean(A::AbstractArray, Estimator::Huber, kwargs...)

Reference: Huber

Statistics.meanMethod
mean(A::AbstractArray, Estimator::δLeeValiant; kwargs...)

Reference: Optimal Sub-Gaussian Mean Estimation in ℝ by Lee et Valiant

Statistics.meanMethod
mean(A::AbstractArray, Estimator::δMinskerNdaoud; kwargs...)

Reference: Robust and efficient mean estimation: an approach based on the properties of self-normalized sums

Statistics.meanMethod
mean(A::AbstractArray, w::AbstractWeights, Estimator::EmpiricalMean)

The usual empirical mean estimator. Nothing fancy.

Statistics.meanMethod

mean(A::AbstractArray, w::AbstractWeights, Estimator::MoM)

The Median of Mean estimator.

Statistics.meanMethod
mean(A::AbstractArray, w::AbstractWeights, Estimator::δLeeValiant; kwargs...)

Reference: Optimal Sub-Gaussian Mean Estimation in R by Lee et Valiant

Statistics.meanMethod
mean(A::AbstractArray, w::AbstractWeights, Estimator::δMinskerNdaoud; kwargs...)

Reference: Robust and efficient mean estimation: an approach based on the properties of self-normalized sums

Statistics.meanMethod
mean(A::AbstractArray, w::AbstractWeights, Estimator::Z_Estimator)

A Z estimator given an influence function x->ψ(x) and a scaling parameter α.

Statistics.meanMethod

mean(A::AbstractArray, Estimator::TrimmedMean)

The Trimmed Mean estimator. (p)

Statistics.meanMethod

mean(A::AbstractArray, Estimator::Z_Estimator)

A Z estimator given an influence function x->ψ(x) and a scaling parameter α.