Skip to content

Commit 8bfdef0

Browse files
Need to specify Matrix::colSums
1 parent a5d33db commit 8bfdef0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

R/sc.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ se_make_pseudobulk <- function(se, on, missing.levels=FALSE, unlevel=TRUE, ncell
1616
mat %*% to_P
1717
})
1818
if ("counts" %in% names(A)) {
19-
Percent <- as.matrix((A$counts > 0) %*% to_P) %*% diag(100/colSums(to_P))
19+
Percent <- as.matrix((A$counts > 0) %*% to_P) %*% diag(100/Matrix::colSums(to_P))
2020
dimnames(Percent) <- dimnames(P$counts)
2121
P$Percent <- Percent
2222
}

0 commit comments

Comments
 (0)