I have a dataframe in R and I am trying to cluster points (lat,long). I'm thinking of using hclust (single linkage) or nearest neighbor. But is there any way that I can stop the clustering algorithm once the clusters are >10km apart? Basically, I want to put a stopping condition to the clustering so it doesn't keep going until it becomes one cluster. But I want to base it on how far apart clusters are, not cut tree value. Is there a way to code this in R?
df$Lat <- c(26.2,26.1,26,26.2,26.2,25.8,25.8)
df$Long <- c(83.9,84,83,84.2,84.3,82,82.1)