... | ... |
@@ -59,19 +59,12 @@ The raw matrix can be passed to the `background` parameter in `decontX` as descr |
59 | 59 |
We will utilize the 10X PBMC 4K dataset as an example in this vignette. This data can be easily retrieved from the package [TENxPBMCData](http://bioconductor.org/packages/release/data/experiment/html/TENxPBMCData.html). Make sure the the column names are set before running decontX. |
60 | 60 |
|
61 | 61 |
```{r load_10X, eval=TRUE, message=FALSE} |
62 |
-# Install TENxPBMCData if is it not already |
|
63 |
-if (!requireNamespace("TENxPBMCData", quietly = TRUE)) { |
|
64 |
- if (!requireNamespace("BiocManager", quietly = TRUE)) { |
|
65 |
- install.packages("BiocManager") |
|
66 |
- } |
|
67 |
- BiocManager::install("TENxPBMCData") |
|
68 |
-} |
|
69 |
- |
|
70 | 62 |
# Load PBMC data |
71 | 63 |
library(TENxPBMCData) |
72 | 64 |
sce <- TENxPBMCData("pbmc4k") |
73 | 65 |
colnames(sce) <- paste(sce$Sample, sce$Barcode, sep = "_") |
74 | 66 |
rownames(sce) <- rowData(sce)$Symbol_TENx |
67 |
+counts(sce) <- as(counts(sce), "dgCMatrix") |
|
75 | 68 |
``` |
76 | 69 |
|
77 | 70 |
|
... | ... |
@@ -59,19 +59,12 @@ The raw matrix can be passed to the `background` parameter in `decontX` as descr |
59 | 59 |
We will utilize the 10X PBMC 4K dataset as an example in this vignette. This data can be easily retrieved from the package [TENxPBMCData](http://bioconductor.org/packages/release/data/experiment/html/TENxPBMCData.html). Make sure the the column names are set before running decontX. |
60 | 60 |
|
61 | 61 |
```{r load_10X, eval=TRUE, message=FALSE} |
62 |
-# Install TENxPBMCData if is it not already |
|
63 |
-if (!requireNamespace("TENxPBMCData", quietly = TRUE)) { |
|
64 |
- if (!requireNamespace("BiocManager", quietly = TRUE)) { |
|
65 |
- install.packages("BiocManager") |
|
66 |
- } |
|
67 |
- BiocManager::install("TENxPBMCData") |
|
68 |
-} |
|
69 |
- |
|
70 | 62 |
# Load PBMC data |
71 | 63 |
library(TENxPBMCData) |
72 | 64 |
sce <- TENxPBMCData("pbmc4k") |
73 | 65 |
colnames(sce) <- paste(sce$Sample, sce$Barcode, sep = "_") |
74 | 66 |
rownames(sce) <- rowData(sce)$Symbol_TENx |
67 |
+counts(sce) <- as(counts(sce), "dgCMatrix") |
|
75 | 68 |
``` |
76 | 69 |
|
77 | 70 |
|