interval_index: Bin values into intervals based on the provided breaks

View source: R/graph_binning.R

interval_indexR Documentation

Bin values into intervals based on the provided breaks

Description

Bin values into intervals based on the provided breaks

Usage

interval_index(x, breaks, out_of_range_intervals = FALSE)

Arguments

x

The values to be binned

breaks

The boundaries between bins

out_of_range_intervals

If TRUE, "out of range" values lying below the first break or above the last break will be assigned to additional unbounded lower and upper extrema intervals. If FALSE these "out of range" values will be assigned to intervals bounded by the lowest or uppermost break respectively.

Value

A vector of bin indexes, one per value provided


alan-turing-institute/network-comparison documentation built on June 7, 2022, 10:41 p.m.