Page 1 of 1

Iterative clustering...

Posted: Mon Mar 02, 2020 4:50 pm
by Bernd Welter
Hi there,

as you might have seen in the xCluster API there are some balancing constraints given , e.g. in planVisits:
- weeklyImbalanceTolerance
- dailyImbalanceTolerance
Now today I've been talking to one of our clustering experts and what could be helpful for you to know is that the primary goal of a clustering is a geographic compactness (balanced results such as "compareable workload on each day" are prio B). If there are several solutions such as
- a solution that minimices the cluster compactness but with a poor balance
- a solution with a proper balance but poor compactness
the algorithm will prefer the first one (better compactness).
Sample result: 4 weeks cycle. Each day's aggregated service period is almost equal. Driving distances differ a bit.
Sample result: 4 weeks cycle. Each day's aggregated service period is almost equal. Driving distances differ a bit.
If you prefer balance over compactness you could approach this as follows (example):
- start with enforcing a specific balance, e.g. 25%
- if the output is found a solution : enforce a better balance, e.g. 20%
- if no solution is found: enforce a more flexible balance, e.g. 30%
and so on...

Depending on the data (deviation of visitRhythms, ...) you could finally find a fair tradeoff between both goals.

Of course this requires some patience as each individual call may take time... applying a "balance" is time consuming...

Best regards,
Bernd