robust_disc {gdverse} | R Documentation |
univariate discretization based on offline change point detection
Description
Determines discretization interval breaks using an optimization algorithm for variance-based change point detection.
Usage
robust_disc(formula, data, discnum, minsize = NULL, cores = 1)
Arguments
formula |
A formula of univariate discretization. |
data |
A data.frame or tibble of observation data. |
discnum |
A numeric vector of discretized classes of columns that need to be discretized. |
minsize |
(optional) The min size of each discretization group. Default all use |
cores |
(optional) A positive integer(default is 1). If cores > 1, use |
Value
A tibble of discretized columns which need to be discretized.
Note
Please set up python dependence and configure GDVERSE_PYTHON
environment variable if you want to run robust_disc()
.
See vignette('RGDRID',package = 'gdverse')
for more details.
Author(s)
Wenbo Lv lyu.geosocial@gmail.com
Examples
## Not run:
## The following code needs to configure the Python environment to run:
data('ndvi')
robust_disc(NDVIchange ~ GDP,data = ndvi,discnum = 5)
robust_disc(NDVIchange ~ .,
data = dplyr::select(ndvi,-c(Climatezone,Mining)),
discnum = 10,cores = 6)
## End(Not run)
[Package gdverse version 1.0-1 Index]