Skip to content

Commit 2b92d15

Browse files
committed
removing unneeded code
1 parent e8a1f79 commit 2b92d15

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

clustering.Rmd

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ There each row corresponds to an iteration,
439439
where the left column depicts the center update,
440440
and the right column depicts the reassignment of data to clusters.
441441

442-
(ref:10-toy-kmeans-iter) First four iterations of K-means clustering on the `penguin_data` example data set. Each pair of plots corresponds to an iteration. Within the pair, the left column depicts the center update, and the right column depicts the reassignment of data to clusters. Cluster centers are indicated by larger points that are outlined in black.
442+
(ref:10-toy-kmeans-iter) First four iterations of K-means clustering on the `penguin_data` example data set. Each pair of plots corresponds to an iteration. Within the pair, the first plot depicts the center update, and the second plot depicts the reassignment of data to clusters. Cluster centers are indicated by larger points that are outlined in black.
443443

444444
```{r 10-toy-kmeans-iter, echo = FALSE, warning = FALSE, fig.height = 4.5, fig.width = 8, fig.align = "center", fig.cap = "(ref:10-toy-kmeans-iter)"}
445445
list_plot_cntrs <- vector(mode = "list", length = 4)
@@ -611,7 +611,7 @@ plt_lbl
611611

612612
Figure \@ref(fig:10-toy-kmeans-bad-iter) shows what the iterations of K-means would look like with the unlucky random initialization shown in Figure \@ref(fig:10-toy-kmeans-bad-init).
613613

614-
(ref:10-toy-kmeans-bad-iter) First five iterations of K-means clustering on the `penguin_data` example data set with a poor random initialization. Each pair of plots corresponds to an iteration. Within the pair, the left column depicts the center update, and the right column depicts the reassignment of data to clusters. Cluster centers are indicated by larger points that are outlined in black.
614+
(ref:10-toy-kmeans-bad-iter) First five iterations of K-means clustering on the `penguin_data` example data set with a poor random initialization. Each pair of plots corresponds to an iteration. Within the pair, the first plot depicts the center update, and the second plot depicts the reassignment of data to clusters. Cluster centers are indicated by larger points that are outlined in black.
615615

616616
```{r 10-toy-kmeans-bad-iter, echo = FALSE, warning = FALSE, fig.height = 6.75, fig.width = 8, fig.align = "center", fig.cap = "(ref:10-toy-kmeans-bad-iter)"}
617617
list_plot_cntrs <- vector(mode = "list", length = 5)
@@ -689,13 +689,6 @@ iter_plot_list <- c(list_plot_cntrs[1], list_plot_lbls[1],
689689
list_plot_cntrs[4], list_plot_lbls[4],
690690
list_plot_cntrs[5], list_plot_lbls[5])
691691
692-
# plot_grid(plotlist = iter_plot_list,
693-
# ncol = 4,
694-
# rel_heights = c(1.10, 1, 1))
695-
696-
ggarrange(plots = iter_plot_list, ncol =4, common.legend = TRUE)
697-
698-
699692
ggarrange(iter_plot_list[[1]] +
700693
theme(axis.text.x = element_blank(),
701694
axis.ticks.x = element_blank(),

0 commit comments

Comments
 (0)