Skip to content

Commit

Permalink
More tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
ddiez committed Jul 18, 2024
1 parent 16edb44 commit 93b3102
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions R/pseudobulk.R
Original file line number Diff line number Diff line change
Expand Up @@ -58,20 +58,21 @@ pseudobulk.Seurat <- function(x, split.by, group.by, samples=NULL, genes=NULL, a
})

dge <- lapply(names(xl), function(n) {
s <- samples
s$cluster <- n
tmp <- edgeR::DGEList(xl[[n]])#, samples=s)
tmp$genes <- genes
#s <- samples
#s$cluster <- n
#tmp <- edgeR::DGEList(xl[[n]])#, samples=s)
#tmp$genes <- genes
tmp <- xl[[n]]
colnames(tmp) <- unname(colnames(tmp))
tmp
})
names(dge) <- names(xl)

if (sort_samples) {
dge <- lapply(dge, function(x) {
x[, sort(rownames(samples))]
})
}
#if (sort_samples) {
# dge <- lapply(dge, function(x) {
# x[, sort(rownames(samples))]
# })
#}

dge
}

0 comments on commit 93b3102

Please sign in to comment.