Filling bins with an equal size

后端 未结 3 1517
予麋鹿
予麋鹿 2021-01-25 18:48

I have 100 groups and each group has some elements inside. For the cross validation, I want to make five bins which their size is as equal as possible.

Is there any algo

3条回答
  •  北恋
    北恋 (楼主)
    2021-01-25 19:19

    If you're looking for a clustering algorithm (partitioning method) with equal size constraint, I would suggest the Spectral Clustering. It will satisfy your demand for clusters with almost the same sizes because it solves the normalized cut problem, which try to find a balanced cut.

提交回复
热议问题