From 282b04dda24e655eb3ebb85c02bcc7d08280c025 Mon Sep 17 00:00:00 2001 From: Aaron Lun Date: Thu, 29 Sep 2022 16:45:53 -0700 Subject: [PATCH] Generate the subsetted immune dataset as RDS as well. --- 10x-immune/generate.R | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/10x-immune/generate.R b/10x-immune/generate.R index e33325d..ecc9083 100644 --- a/10x-immune/generate.R +++ b/10x-immune/generate.R @@ -6,7 +6,8 @@ se <- read10xCounts("immune_3.0.0-tenx.h5") source("../_scripts/compact10x.R") -sub <- se[,1:3000] +keep <- 1:3000 +sub <- se[,keep] path <- "immune_3.0.0_sub-tenx.h5" unlink(path) compact10x(path, assay(sub), rownames(sub), rowData(sub)$Symbol) @@ -33,4 +34,5 @@ rownames(altExp(sce)) <- rownames(rd) assay(altExp(sce)) <- as.matrix(assay(altExp(sce))) saveRDS(sce, "immune_3.0.0-tenx.rds") +saveRDS(sce[,keep], "immune_3.0.0_sub-tenx.rds")