dataDiscretize: Discretize data

Description

These functions discretize continuous input data into classes. Classes can be defined
by the user or, if the user provides the number of expected classes, calculated
from quantiles (default option) or by equal intervals.dataDiscretize processes a single variable at a time, provided as vector.
bulkDiscretize discretizes multiple input rasters, by using parallel processing.

Usage

1
2
3
4

Arguments

data

numeric vector. The continuous data to be discretized.

classBoundaries

numeric vector or single integer. Interval boundaries to be used for data discretization.
Outer values (minimum and maximum) required. -Inf or Inf are allowed, in which case
data minimum and maximum will be used to evaluate the mid values of outer classes. Alternatively, a single integer to
indicate the number of classes, to split by quantiles (default) or equal intervals.

classStates

vector. The state labels to be assigned to the discretized data.

method

character. What splitting method should be used? This argument is ignored if
a vector of values is passed to classBoundaries.

quantile splits data into quantiles (default).

equal splits data into equally sized intervals based on data minimum and maximum.

formattedLst

A formatted list as returned by linkNode and linkMultiple

xy

matrix. A matrix of spatial coordinates; first column is x (longitude), second column is y (latitude) of locations (in rows).

inparallel

logical or integer. Should the function use parallel processing facilities? Default is FALSE: a single process will be launched. If TRUE, all cores/processors but one will be used.
Alternatively, an integer can be provided to dictate the number of cores/processors to be used.