According to http://scikit-learn.org/stable/modules/generated/sklearn.cluster.AgglomerativeClustering.html#sklearn.cluster.AgglomerativeClustering linkage types are : {“ward”, “complete”, “average”, “single”}, optional (default=”ward”).
But once I try to use single I obtain
Unknown linkage type single.Valid options are dict_keys(['ward', 'average', 'complete'].
Is it possible to set linkage to "single"? Scikit-learn version I use is 0.20.0.
Minimal not-working code:
from sklearn.cluster import AgglomerativeClustering
import numpy as np
X = np.array([[1, 2], [1, 4], [1, 0],
[4, 2], [4, 4], [4, 0]])
clustering = AgglomerativeClustering( linkage='single').fit(X)