Is there any definition on the range of entry dates to be included in a group/cluster. I don't see any defined range in the sheet you provide. They are clustered manually.
That visual clustering I did it manually just to illustrate how they need to be grouped
But the cluster calculation is dynamic, there is no column that indicates which row belongs to which cluster, the criteria would be the following:
Cluster 1 = 10 most recent trades by "Entry Date"
Custer 2 = next 10 most recent trades not included in Cluster 1
Cluster 3 = next 10 most recent trades not included in Cluster 1 or 2
Cluster X = the remaining trades not included in any previous cluster
The same logic applies for clusters of 20
As new records get added the rows in the each cluster will change
Do you know if there is any unique identifier for each row ?