Klustering verwys na die proses om soortgelyke voorwerpe of datapunte saam te groepeer op grond van sekere kriteria, soos hul nabyheid of ooreenkoms. In rekenaarwetenskap en masjienleer word groepering dikwels gebruik as 'n tegniek vir verkennende data-analise, data-ontginning en patroonherkenning. Groeperingsalgoritmes poog om patrone of strukture in data te identifiseer deur hulle te verdeel in groepe, of trosse, wat soortgelyke kenmerke of eienskappe het. Die doel is om die ooreenkoms tussen voorwerpe binne 'n groep te maksimeer, terwyl die ooreenkoms tussen voorwerpe in verskillende groepe tot die minimum beperk word.