Skip to content

Commit 638d590

Browse files
NelleVGaelVaroquaux
authored andcommitted
FIX spelling mistakes and whitespace nitpick
1 parent 017de2e commit 638d590

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

sklearn/cluster/hierarchical.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -243,16 +243,16 @@ def linkage_tree(X, connectivity=None, n_components=None, copy=True,
243243
244244
The inertia matrix uses a Heapq-based representation.
245245
246-
This is the structured version, that takes into account a some topological
246+
This is the structured version, that takes into account some topological
247247
structure between samples.
248248
249249
Parameters
250250
----------
251251
X : array of shape (n_samples, n_features)
252-
feature matrix representing n_samples samples to be clustered
252+
feature matrix representing n_samples samples to be clustered
253253
254254
connectivity : sparse matrix (optional).
255-
connectivity matrix. Defines for each sample the neigbhoring samples
255+
connectivity matrix. Defines for each sample the neighboring samples
256256
following a given structure of the data. The matrix is assumed to
257257
be symmetric and only the upper triangular half is used.
258258
Default is None, i.e, the Ward algorithm is unstructured.
@@ -284,7 +284,7 @@ def linkage_tree(X, connectivity=None, n_components=None, copy=True,
284284
The number of connected components in the graph.
285285
286286
n_leaves : int
287-
The number of leaves in the tree
287+
The number of leaves in the tree.
288288
289289
parents : 1D array, shape (n_nodes, ) or None
290290
The parent of each node. Only returned when a connectivity matrix
@@ -580,7 +580,7 @@ class Ward(AgglomerativeClustering):
580580
connectivity : sparse matrix (optional)
581581
Connectivity matrix. Defines for each sample the neigbhoring
582582
samples following a given structure of the data.
583-
Default is None, i.e, the hiearchical clustering algorithm is
583+
Default is None, i.e, the hierarchical clustering algorithm is
584584
unstructured.
585585
586586
memory : Instance of joblib.Memory or string (optional)
@@ -600,7 +600,7 @@ class Ward(AgglomerativeClustering):
600600
useful to decrease computation time if the number of clusters is
601601
not small compared to the number of samples. This option is
602602
useful only when specifying a connectivity matrix. Note also that
603-
when varying the number of cluster and using caching, it may
603+
when varying the number of clusters and using caching, it may
604604
be advantageous to compute the full tree.
605605
606606
@@ -647,7 +647,7 @@ class WardAgglomeration(AgglomerationTransform, Ward):
647647
connectivity : sparse matrix
648648
connectivity matrix. Defines for each feature the neigbhoring
649649
features following a given structure of the data.
650-
Default is None, i.e, the hiearchical agglomeration algorithm is
650+
Default is None, i.e, the hierarchical agglomeration algorithm is
651651
unstructured.
652652
653653
memory : Instance of joblib.Memory or string
@@ -682,7 +682,7 @@ class WardAgglomeration(AgglomerationTransform, Ward):
682682
cluster labels for each feature
683683
684684
`n_leaves_` : int
685-
Number of leaves in the hiearchical tree.
685+
Number of leaves in the hierarchical tree.
686686
687687
"""
688688

0 commit comments

Comments
 (0)