Skip to contents

The grid with every probability below eps set to 0: the round-off an FFT leaves where the true mass is zero, as aggregate's remove_fuzz. tower_on_grid()'s ceded and net grids already have it removed.

Usage

remove_fuzz(grid, eps = .Machine$double.eps)

Arguments

grid

A grid_distribution.

eps

The threshold, machine epsilon by default.

Value

A grid_distribution.

Examples

remove_fuzz(grid_distribution(1, c(0.5, 0.5 - 1e-20, 1e-20)))@probs
#> [1] 0.5 0.5 0.0