开发者

Discretization in R

Is anyone aware of a packag开发者_如何学Pythone that implements a supervised learning algorithm for the discretization of continuous variables?

The dprep package contained functions along this line, but the package has been deprecated. Any ideas?

Thanks for your help!


You can still use the dprep package, but you have to install it from source (I just tested and it works well). However, you may well have a look at the discretization or infotheo packages which provide similar functionalities, e.g. equal interval width, equal frequency intervals, ChiMerge, etc.


A simple example using infotheo

> set.seed(1)
> infotheo::discretize(rnorm(10))
   X
1  1
2  1
3  1
4  2
5  2
6  1
7  2
8  2
9  2
10 1
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜