Skip to content

Commit

Permalink
workflowr::wflow_publish("assess_fits_droplet.Rmd", verbose = TRUE)
Browse files Browse the repository at this point in the history
  • Loading branch information
pcarbo committed Jul 30, 2024
1 parent 80f7678 commit 1eb8b9d
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions analysis/assess_fits_droplet.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ additional functions for creating the plots.
library(fastTopics)
library(ggplot2)
library(cowplot)
set.seed(1)
source("../code/plot_functions.R")
```

Load the results of running `fit_poisson_nmf` on the droplet data,
Expand Down Expand Up @@ -125,3 +127,27 @@ ggsave("../plots/loadings_scatterplot_droplet_k7.eps",
p1,height = 2.5,width = 2.6)
```

Finally, let's have a look at the results of running LDA with the
various initializations:

```{r elbo-plots, fig.height=6, fig.width=9}
load("../output/droplet/lda-droplet.RData")
p <- vector("list",12)
for (i in 2:12) {
runs <- which(dat$k == i)
p[[i]] <- create_elbo_plot(fits[runs],dat[runs,"runtime"],i)
}
plot_grid(p[[2]],p[[3]],p[[4]],p[[5]],
p[[6]],p[[7]],p[[8]],p[[9]],
p[[10]],p[[11]],p[[12]],
nrow = 3,ncol = 4)
```

```{r plots-for-paper-4, message=FALSE, echo=FALSE}
ggsave("../plots/lda_elbo_droplet.eps",
plot_grid(p[[2]],p[[3]],p[[4]],p[[5]],
p[[6]],p[[7]],p[[8]],p[[9]],
p[[10]],p[[11]],p[[12]],
nrow = 3,ncol = 4),
height = 6,width = 9)
```

0 comments on commit 1eb8b9d

Please sign in to comment.