SignalEncodings functions

This page documents the bin methods provided by SignalEncodings.jl.

bin converts numeric data into integer bin indices and returns a tuple of:

  • X_bin: binned values as UInt8
  • edges: learned bin boundaries

The exact return shape depends on the input layout:

  • AbstractVector{<:Real}: a binned vector and one edge vector
  • AbstractArray{<:Real}: one binned vector per feature/column
  • Matrix{<:AbstractArray}: preserves the original cell layout for time series, images, and tensors

Common behavior

All binning methods follow the same general pattern:

  1. select a subset of observations when edge estimation would be too expensive,
  2. learn bin boundaries from the selected values,
  3. map each observation to its bin index.

The max_nobs and rng fields of the configuration control subsampling.

Vector binning

Uniform binning

Uniform binning uses linearly spaced edges between the minimum and maximum value.

Missing docstring.

Missing docstring for bin(::Uniform, ::AbstractVector{<:Real}). Check Documenter's build log for details.

Quantile binning

Quantile binning places edges at empirical quantile positions.

Missing docstring.

Missing docstring for bin(::Quantile, ::AbstractVector{<:Real}). Check Documenter's build log for details.

Jenks binning

Jenks binning iteratively adjusts class breaks to reduce within-bin deviation.

Missing docstring.

Missing docstring for bin(::Jenks, ::AbstractVector{<:Real}). Check Documenter's build log for details.

Tabular data

For matrices of numeric values, each column is binned independently.

Missing docstring.

Missing docstring for bin(::BinningConfig, ::AbstractArray{<:Real}). Check Documenter's build log for details.

get_idxs ```