<- SingleCellExperiment(assays = list(counts = cbind(cov.1, cov.15, cov.17, ctrl.5, ctrl.13, ctrl.14)))
sce dim(sce)
diff --git a/docs/home_contents.html b/docs/home_contents.html index ea0e9c12..81f9e258 100644 --- a/docs/home_contents.html +++ b/docs/home_contents.html @@ -120,6 +120,11 @@ Info +
Updated: 18-01-2024 at 17:22:21.
+Updated: 23-01-2024 at 11:35:27.
16-Jan-2024
+23-Jan-2024
We can now load the expression matrices and merge them into a single object. Each analysis workflow (Seurat, Scater, Scanpy, etc) has its own way of storing data. We will add dataset labels as cell.ids just in case you have overlapping barcodes between the datasets. After that we add a column Chemistry in the metadata for plotting later on.
+We can now merge them objects into a single object. Each analysis workflow (Seurat, Scater, Scanpy, etc) has its own way of storing data. We will add dataset labels as cell.ids just in case you have overlapping barcodes between the datasets. After that we add a column type in the metadata to define covid and ctrl samples.
sce <- SingleCellExperiment(assays = list(counts = cbind(cov.1, cov.15, cov.17, ctrl.5, ctrl.13, ctrl.14)))
dim(sce)
used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 10216587 545.7 17147474 915.8 13915408 743.2
-Vcells 44612623 340.4 94446392 720.6 83350999 636.0
+Ncells 10216383 545.7 17147170 915.8 13915194 743.2
+Vcells 44612100 340.4 94440822 720.6 83350476 636.0
Here is how the count matrix and the metadata look like for every cell.
@@ -475,7 +480,7 @@As you can see, there is quite some difference in quality for the 4 datasets, with for instance the covid_15 sample having fewer cells with many detected genes and more mitochondrial content. As the ribosomal proteins are highly expressed they will make up a larger proportion of the transcriptional landscape when fewer of the lowly expressed genes are detected. And we can plot the different QC-measures as scatter plots.
+As you can see, there is quite some difference in quality for the 4 datasets, with for instance the covid_15 and covid_16 samples having fewer cells with many detected genes and more mitochondrial content. As the ribosomal proteins are highly expressed they will make up a larger proportion of the transcriptional landscape when fewer of the lowly expressed genes are detected. We can also plot the different QC-measures as scatter plots.
As the level of expression of mitochondrial and MALAT1 genes are judged as mainly technical, it can be wise to remove them from the dataset before any further analysis.
+As the level of expression of mitochondrial and MALAT1 genes are judged as mainly technical, it can be wise to remove them from the dataset before any further analysis. In this case we will also remove the HB genes.
genes_file <- file.path(path_results, "genes_table.csv")
@@ -679,7 +684,19 @@
+
+
+
+
+
+Discuss
+
+
+
+Here, we can see clearly that we have three males and five females, can you see which samples they are? Do you think this will cause any problems for downstream analysis? Discuss with your group: what would be the best way to deal with this type of sex bias?
+
+
sce.filt <- sce.filt[, sce.filt$scDblFinder.score < 2]
dim(sce.filt)
[1] 18183 6023
+[1] 18186 6023
[[1]]
-[1] 923 454
+[1] 923 500
[[2]]
-[1] 611 454
+[1] 611 500
[[3]]
-[1] 1111 454
+[1] 1111 500
[[4]]
-[1] 1067 454
+[1] 1067 500
[[5]]
-[1] 1203 454
+[1] 1203 500
[[6]]
-[1] 1108 454
+[1] 1108 500
INTEG_R5:
@@ -901,7 +906,7 @@# Visualizing the expression of one
markers_genes[["1"]]
DataFrame with 18183 rows and 11 columns
- p.value FDR summary.logFC logFC.2 logFC.3
- <numeric> <numeric> <numeric> <numeric> <numeric>
-S100A8 5.01536e-64 9.11942e-60 6.628056 7.76621 2.340367
-S100A12 5.88901e-53 5.35399e-49 1.787072 4.27763 1.787072
-S100A9 2.54322e-28 1.54144e-24 1.421390 7.39019 1.421390
-CXCL8 5.98014e-15 2.71842e-11 1.102967 1.58992 1.102967
-PLBD1 2.42988e-14 8.83649e-11 0.987264 2.43642 0.987264
-... ... ... ... ... ...
-AC007325.4 1 1 0.01104654 0.01104654 -0.004812566
-AL354822.1 1 1 -0.00785244 -0.00785244 0.000868684
-AC004556.1 1 1 0.02294381 -0.02462402 -0.124791403
-AC233755.1 1 1 -0.00670799 -0.00670799 0.000000000
-AC240274.1 1 1 -0.00724362 -0.00724362 -0.007032607
- logFC.4 logFC.5 logFC.6 logFC.7 logFC.8
- <numeric> <numeric> <numeric> <numeric> <numeric>
-S100A8 7.89619 7.78462 7.94406 7.88144 6.62806
-S100A12 4.31600 4.28998 4.31586 4.31295 4.26648
-S100A9 7.50841 7.42086 7.55250 7.55379 6.29102
-CXCL8 1.68719 1.54233 1.63129 1.63792 1.53139
-PLBD1 2.43135 2.44121 2.44252 2.44082 2.40550
-... ... ... ... ... ...
-AC007325.4 -0.00271371 0.00667792 0.00417983 0.00809222 0.0110465
-AL354822.1 -0.01036855 -0.00936705 -0.00928158 -0.01539009 -0.0490755
-AC004556.1 -0.04927666 -0.01090129 -0.05200271 -0.04487633 0.0229438
-AC233755.1 0.00000000 0.00000000 0.00000000 0.00000000 0.0000000
-AC240274.1 -0.01510737 -0.01125536 -0.00103067 -0.00380232 -0.0143902
- logFC.9
- <numeric>
-S100A8 6.27635
-S100A12 3.88182
-S100A9 4.81815
-CXCL8 1.54518
-PLBD1 1.81260
-... ...
-AC007325.4 -0.00652380
-AL354822.1 -0.00783011
-AC004556.1 -0.14233685
-AC233755.1 0.00000000
-AC240274.1 -0.01826009
+DataFrame with 18186 rows and 11 columns
+ p.value FDR summary.logFC logFC.2 logFC.3
+ <numeric> <numeric> <numeric> <numeric> <numeric>
+S100A12 1.57321e-139 2.86104e-135 2.34116 4.13134 2.34116
+S100A8 1.35706e-64 1.23397e-60 6.52478 7.66360 3.33664
+S100A9 1.40449e-61 8.51405e-58 6.19181 7.33443 2.41140
+PLBD1 3.89784e-49 1.77215e-45 1.28043 2.32483 1.28043
+NAMPT 7.45257e-38 2.71065e-34 1.27817 2.67891 1.27817
+... ... ... ... ... ...
+AC007325.4 1 1 0.00966451 0.00966451 0.000585433
+AL354822.1 1 1 -0.00710162 -0.00710162 0.000697440
+AC004556.1 1 1 -0.04593904 -0.05277778 -0.107041903
+AC233755.1 1 1 -0.00643585 -0.00643585 0.000000000
+AC240274.1 1 1 -0.00464419 -0.00464419 -0.003523507
+ logFC.4 logFC.5 logFC.6 logFC.7 logFC.8
+ <numeric> <numeric> <numeric> <numeric> <numeric>
+S100A12 4.17448 4.16371 4.16654 4.16271 4.11649
+S100A8 7.78141 7.69505 7.80820 7.76011 6.52478
+S100A9 7.42537 7.40085 7.47624 7.47041 6.19181
+PLBD1 2.32076 2.33067 2.33183 2.32822 2.28943
+NAMPT 2.76442 2.68668 2.75854 2.86208 2.81797
+... ... ... ... ... ...
+AC007325.4 -0.00472268 0.00533155 0.003317156 0.007609982 0.00966451
+AL354822.1 -0.00667383 -0.00850239 -0.008013634 -0.012927623 -0.01634707
+AC004556.1 -0.04331115 -0.01255718 -0.045939045 -0.042512552 0.01815203
+AC233755.1 0.00000000 0.00000000 0.000000000 0.000000000 0.00000000
+AC240274.1 -0.00702685 -0.00810242 0.000772945 -0.000256299 -0.01576446
+ logFC.9
+ <numeric>
+S100A12 4.12539
+S100A8 6.89910
+S100A9 5.25571
+PLBD1 1.85508
+NAMPT 1.62395
+... ...
+AC007325.4 -0.0146342
+AL354822.1 -0.0131441
+AC004556.1 -0.1608256
+AC233755.1 0.0000000
+AC240274.1 -0.0229031
We can now select the top 25 up regulated genes for plotting.
@@ -355,7 +360,7 @@
B cell CD4 T cell CD8 T cell cDC cMono ncMono
- 70 104 125 38 215 160
+ 69 105 124 38 215 160
NK cell pDC Plasma cell unassigned
- 294 2 1 194
+ 294 2 1 195
Then add the predictions to metadata and plot UMAP.
@@ -451,10 +456,10 @@cell_type_pred
- B cell CD4 T cell CD8 T cell cDC cMono ncMono
- 101 161 293 37 241 164
- NK cell pDC Plasma cell
- 203 2 1
+ B cell CD4 T cell CD8 T cell cDC cMono ncMono NK cell
+ 102 176 300 65 187 189 182
+ pDC
+ 2
Then add the predictions to metadata and plot umap.
@@ -594,7 +599,7 @@$`1`
- pathway pval padj ES NES nMoreExtreme size
-1: cMono 0.0001612123 0.0005946089 0.9477365 1.935642 0 47
-2: ncMono 0.0001611344 0.0005946089 0.8883004 1.824343 0 49
-3: cDC 0.0581929556 0.0654670750 -0.7642090 -1.413663 265 17
-4: Plasma cell 0.0263583815 0.0338893476 -0.7559870 -1.492311 113 24
-5: NK cell 0.0018440464 0.0027660695 -0.7327226 -1.663502 6 49
-6: CD8 T cell 0.0011008366 0.0019815059 -0.8963974 -1.673679 4 18
-7: B cell 0.0002632272 0.0005946089 -0.9032392 -2.032917 0 47
-8: CD4 T cell 0.0002642706 0.0005946089 -0.9254862 -2.108715 0 50
- leadingEdge
-1: S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
-2: S100A11,AIF1,S100A4,FCER1G,MAFB,SERPINA1,...
-3: HLA-DPB1,HLA-DPA1,HLA-DQB1,HLA-DRB1,HLA-DMA,HLA-DRB5,...
-4: ISG20,PEBP1,CYCS,MIF,FKBP11,SPCS2,...
-5: GNLY,NKG7,B2M,CTSW,GZMA,FGFBP2,...
-6: IL32,CCL5,GZMH,CD3D,CD2,CD8A,...
-7: RPS5,CXCR4,RPL23A,CD52,RPL18A,RPL13A,...
-8: RPL3,RPS4X,RPS27A,RPL5,EEF1A1,RPL14,...
+ pathway pval padj ES NES nMoreExtreme size
+1: cMono 0.0001327492 0.0007607777 0.9515770 1.824481 0 47
+2: ncMono 0.0003952048 0.0007607777 0.8775149 1.692495 2 49
+3: NK cell 0.0070510162 0.0105765243 -0.6936107 -1.614830 16 49
+4: CD8 T cell 0.0002904444 0.0007607777 -0.9042254 -1.737436 0 18
+5: B cell 0.0004050223 0.0007607777 -0.9085213 -2.107981 0 47
+6: CD4 T cell 0.0004226543 0.0007607777 -0.9246391 -2.155367 0 50
+ leadingEdge
+1: S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
+2: S100A11,AIF1,S100A4,FCER1G,MAFB,SAT1,...
+3: GNLY,NKG7,CTSW,GZMA,B2M,GZMM,...
+4: IL32,CCL5,GZMH,CD3D,CD2,CD8A,...
+5: RPS5,CXCR4,RPL23A,CD52,RPL18A,RPL13A,...
+6: RPL3,RPS4X,RPS27A,RPL5,EEF1A1,RPL14,...
$`2`
- pathway pval padj ES NES nMoreExtreme size
-1: B cell 0.0002041650 0.0003700658 0.9650595 2.060454 0 47
-2: CD4 T cell 0.0002055921 0.0003700658 0.8591045 1.846955 0 50
-3: cDC 0.0004203447 0.0006305170 0.9445632 1.709807 1 17
-4: CD8 T cell 0.0021048603 0.0027062490 -0.8921894 -1.641239 10 18
-5: cMono 0.0001959248 0.0003700658 -0.8185447 -1.761319 0 47
-6: ncMono 0.0001940994 0.0003700658 -0.8829761 -1.915489 0 49
-7: NK cell 0.0001940994 0.0003700658 -0.9127279 -1.980031 0 49
+ pathway pval padj ES NES nMoreExtreme size
+1: B cell 0.0001973554 0.000365408 0.9639203 2.032368 0 47
+2: CD4 T cell 0.0001970055 0.000365408 0.8696162 1.846240 0 50
+3: cDC 0.0001979806 0.000365408 0.9506666 1.711665 0 17
+4: CD8 T cell 0.0016083635 0.002067896 -0.8930677 -1.641590 7 18
+5: cMono 0.0008105370 0.001215805 -0.7964559 -1.721447 3 47
+6: ncMono 0.0002030045 0.000365408 -0.8998544 -1.960178 0 49
+7: NK cell 0.0002030045 0.000365408 -0.9119291 -1.986480 0 49
leadingEdge
-1: MS4A1,CD37,TNFRSF13C,CXCR4,BANK1,CD79B,...
+1: MS4A1,CD37,CXCR4,TNFRSF13C,BANK1,CD79B,...
2: RPS6,RPL13,RPL32,RPS3A,RPS29,RPL3,...
3: HLA-DRA,HLA-DPB1,HLA-DQB1,HLA-DRB1,HLA-DPA1,HLA-DMA,...
4: CCL5,IL32,GZMH,CD3D,CD2,LYAR,...
-5: S100A6,S100A9,LYZ,S100A8,TYROBP,FCN1,...
-6: S100A4,FCER1G,S100A11,AIF1,IFITM3,LST1,...
+5: S100A6,S100A9,TYROBP,LYZ,S100A8,FCN1,...
+6: S100A4,FCER1G,S100A11,AIF1,LST1,IFITM3,...
7: HCST,NKG7,ITGB2,GNLY,MYO1F,CST7,...
$`3`
- pathway pval padj ES NES nMoreExtreme size
-1: ncMono 0.0001041124 0.0004694836 0.9309715 1.625137 0 49
-2: cMono 0.0001043297 0.0004694836 0.9315183 1.624154 0 47
-3: cDC 0.0168105930 0.0216136195 0.8590261 1.386413 145 17
-4: CD4 T cell 0.0026666667 0.0040000000 -0.7020776 -1.886878 0 50
-5: NK cell 0.0025188917 0.0040000000 -0.7120017 -1.914447 0 49
-6: CD8 T cell 0.0007980846 0.0023942538 -0.9359176 -2.017558 0 18
-7: B cell 0.0023980815 0.0040000000 -0.8774013 -2.326466 0 47
- leadingEdge
-1: AIF1,PSAP,S100A11,FCER1G,S100A4,SERPINA1,...
-2: S100A9,LYZ,S100A8,FCN1,TYROBP,S100A6,...
-3: HLA-DRA,HLA-DRB1,HLA-DRB5,HLA-DQB1,HLA-DPA1,HLA-DMA,...
-4: RPL3,PIK3IP1,IL7R,RPS29,RPS3,RPS27A,...
-5: NKG7,GNLY,CST7,GZMA,CTSW,GZMM,...
-6: CCL5,IL32,GZMH,CD3D,CD2,CD8A,...
-7: CXCR4,MS4A1,TNFRSF13C,CD79B,BANK1,RPS5,...
+ pathway pval padj ES NES nMoreExtreme size
+1: cMono 0.0001162115 0.0005229518 0.9366715 1.754906 0 47
+2: ncMono 0.0001152206 0.0005229518 0.9282959 1.748653 0 49
+3: cDC 0.0058249797 0.0074892596 0.8938512 1.504106 42 17
+4: Plasma cell 0.0304961311 0.0343081475 -0.7003557 -1.517735 66 24
+5: NK cell 0.0007558579 0.0011583012 -0.7163352 -1.783214 0 49
+6: CD8 T cell 0.0003958828 0.0011583012 -0.9181589 -1.871343 0 18
+7: CD4 T cell 0.0007722008 0.0011583012 -0.7661201 -1.917423 0 50
+8: B cell 0.0007158196 0.0011583012 -0.8988784 -2.222805 0 47
+ leadingEdge
+1: LYZ,S100A9,S100A8,FCN1,TYROBP,S100A6,...
+2: AIF1,PSAP,S100A4,FCER1G,S100A11,COTL1,...
+3: HLA-DRA,HLA-DRB1,HLA-DRB5,HLA-DPA1,HLA-DQB1,HLA-DPB1,...
+4: ISG20,CYCS,FKBP11,JCHAIN,MZB1,PEBP1,...
+5: NKG7,CST7,GZMM,CTSW,GZMA,FGFBP2,...
+6: CCL5,IL32,CD3D,GZMH,CD2,CD8A,...
+7: PIK3IP1,RPS29,IL7R,RPS27A,RPL3,RPS3,...
+8: CXCR4,MS4A1,CD79B,RPS5,TNFRSF13C,BANK1,...
$`4`
pathway pval padj ES NES nMoreExtreme size
-1: CD4 T cell 0.0001930875 0.0004653568 0.9803622 2.131622 0 50
-2: NK cell 0.0275077559 0.0412616339 -0.6668272 -1.466630 132 49
-3: cDC 0.0001991239 0.0004653568 -0.9322686 -1.728863 0 17
-4: pDC 0.0006202191 0.0011163945 -0.8171519 -1.789912 2 47
-5: cMono 0.0002067397 0.0004653568 -0.9186945 -2.012333 0 47
-6: ncMono 0.0002068252 0.0004653568 -0.9263802 -2.037495 0 49
+1: CD4 T cell 0.0002101723 0.0004728878 0.9821321 2.134294 0 50
+2: NK cell 0.0339112212 0.0508668318 -0.6722891 -1.452462 177 49
+3: cDC 0.0001847404 0.0004728878 -0.9340033 -1.702542 0 17
+4: pDC 0.0005699088 0.0010258359 -0.8226825 -1.767306 2 47
+5: cMono 0.0001899696 0.0004728878 -0.9129405 -1.961201 0 47
+6: ncMono 0.0001905125 0.0004728878 -0.9484681 -2.049139 0 49
leadingEdge
-1: IL7R,LDHB,PIK3IP1,NOSIP,RPL3,RPS12,...
-2: NKG7,GNLY,FGFBP2,MYO1F,CST7,GZMA,...
+1: IL7R,LDHB,PIK3IP1,RPL3,RPS12,RPL13,...
+2: NKG7,GNLY,MYO1F,FGFBP2,CST7,ITGB2,...
3: HLA-DRA,HLA-DRB1,HLA-DPA1,HLA-DPB1,HLA-DQB1,HLA-DMA,...
-4: PLEK,NPC2,IRF8,PLAC8,PTPRE,CTSB,...
-5: S100A9,S100A8,LYZ,TYROBP,FCN1,APLP2,...
-6: FCER1G,PSAP,IFITM3,LYN,SAT1,LST1,...
+4: PLEK,NPC2,PLAC8,IRF8,CTSB,PTPRE,...
+5: S100A9,TYROBP,S100A8,LYZ,FCN1,APLP2,...
+6: FCER1G,PSAP,IFITM3,LST1,SAT1,AIF1,...
$`5`
pathway pval padj ES NES nMoreExtreme size
-1: B cell 0.0001818182 0.0004016064 0.9624502 2.052882 0 47
-2: CD4 T cell 0.0001812251 0.0004016064 0.8762641 1.886926 0 50
-3: cDC 0.0001904399 0.0004016064 0.9538608 1.738185 0 17
-4: CD8 T cell 0.0004203447 0.0006305170 -0.9046911 -1.711837 1 18
-5: cMono 0.0008884940 0.0011423494 -0.7954796 -1.765723 3 47
-6: ncMono 0.0002231147 0.0004016064 -0.8859954 -1.977394 0 49
-7: NK cell 0.0002231147 0.0004016064 -0.9087684 -2.028219 0 49
+1: B cell 0.0001963479 0.0003684749 0.9641767 2.042223 0 47
+2: CD4 T cell 0.0001947799 0.0003684749 0.8825397 1.887378 0 50
+3: cDC 0.0002023063 0.0003684749 0.9586399 1.728487 0 17
+4: CD8 T cell 0.0013938670 0.0020908005 -0.8995956 -1.657233 6 18
+5: cMono 0.0018333673 0.0023571865 -0.7742663 -1.687829 8 47
+6: ncMono 0.0002047083 0.0003684749 -0.9119300 -1.999937 0 49
+7: NK cell 0.0002047083 0.0003684749 -0.9130713 -2.002440 0 49
leadingEdge
1: MS4A1,CD37,CXCR4,TNFRSF13C,BANK1,LINC00926,...
-2: RPS6,RPL13,RPL32,RPS3A,RPL9,RPL3,...
+2: RPS6,RPL13,RPL32,RPS3A,RPL9,RPS29,...
3: HLA-DRA,HLA-DQB1,HLA-DRB1,HLA-DPB1,HLA-DPA1,HLA-DMA,...
4: CCL5,IL32,GZMH,CD3D,CD2,LYAR,...
-5: S100A6,S100A9,LYZ,S100A8,TYROBP,FCN1,...
-6: S100A4,FCER1G,S100A11,AIF1,PSAP,IFITM3,...
-7: HCST,NKG7,ITGB2,GNLY,MYO1F,CST7,...
+5: S100A6,S100A9,LYZ,TYROBP,S100A8,FCN1,...
+6: S100A4,FCER1G,S100A11,AIF1,PSAP,LST1,...
+7: ITGB2,NKG7,HCST,GNLY,MYO1F,CST7,...
$`6`
pathway pval padj ES NES nMoreExtreme size
-1: NK cell 0.0001968117 0.0003660024 0.9357367 2.012182 0 49
-2: CD4 T cell 0.0001970443 0.0003660024 0.8648575 1.865254 0 50
-3: CD8 T cell 0.0002002804 0.0003660024 0.9667190 1.776197 0 18
-4: cDC 0.0047732697 0.0071599045 -0.8811814 -1.612760 23 17
-5: ncMono 0.0002032107 0.0003660024 -0.8655401 -1.895657 0 49
-6: cMono 0.0002033347 0.0003660024 -0.9182094 -1.999151 0 47
+1: NK cell 0.0001863586 0.0003882657 0.9383295 1.976633 0 49
+2: CD4 T cell 0.0001846381 0.0003882657 0.8789241 1.861605 0 50
+3: CD8 T cell 0.0001971220 0.0003882657 0.9670054 1.759568 0 18
+4: pDC 0.0952073931 0.1224095054 -0.6041872 -1.319390 442 47
+5: cDC 0.0034246575 0.0051369863 -0.8829998 -1.620873 16 17
+6: ncMono 0.0002157032 0.0003882657 -0.8872842 -1.952006 0 49
+7: cMono 0.0002149151 0.0003882657 -0.9085014 -1.983934 0 47
leadingEdge
1: NKG7,GNLY,CST7,GZMA,CTSW,GZMM,...
-2: IL7R,RPS3,RPS29,RPL3,MGAT4A,RPS4X,...
+2: IL7R,RPS3,RPS29,RPL3,RPL13,RPS6,...
3: CCL5,IL32,GZMH,CD3D,LYAR,CD8A,...
-4: HLA-DRA,HLA-DMA,HLA-DQB1,HLA-DRB5,BASP1,HLA-DRB1,...
-5: FCER1G,AIF1,LST1,FTH1,COTL1,PSAP,...
-6: S100A9,S100A8,LYZ,TYROBP,FCN1,VCAN,...
+4: NPC2,CTSB,IRF8,UNC93B1,PLEK,TCF4,...
+5: HLA-DRA,HLA-DQB1,HLA-DRB5,HLA-DMA,HLA-DRB1,BASP1,...
+6: FCER1G,AIF1,LST1,FTH1,COTL1,PSAP,...
+7: S100A9,S100A8,LYZ,TYROBP,FCN1,TKT,...
$`7`
pathway pval padj ES NES nMoreExtreme size
-1: NK cell 0.0002246686 0.0006740058 0.9822433 2.117581 0 49
-2: CD8 T cell 0.0052356021 0.0067314884 0.8934917 1.648012 23 18
-3: cDC 0.0007408779 0.0016233766 -0.9096050 -1.649017 3 17
-4: ncMono 0.0025220681 0.0037831021 -0.7690981 -1.653101 13 49
-5: CD4 T cell 0.0009018759 0.0016233766 -0.8069090 -1.736711 4 50
-6: cMono 0.0001806685 0.0006740058 -0.8740244 -1.867198 0 47
-7: B cell 0.0001806685 0.0006740058 -0.8943406 -1.910600 0 47
+1: NK cell 0.0002319109 0.0006957328 0.9845619 2.113823 0 49
+2: CD8 T cell 0.0048098946 0.0061841503 0.9021784 1.664902 20 18
+3: cDC 0.0005337129 0.0009606832 -0.9182682 -1.651815 2 17
+4: CD4 T cell 0.0008767315 0.0013150973 -0.7915340 -1.672841 4 50
+5: ncMono 0.0005272408 0.0009606832 -0.8127856 -1.712117 2 49
+6: cMono 0.0001757469 0.0006957328 -0.8702759 -1.823002 0 47
+7: B cell 0.0001757469 0.0006957328 -0.8859815 -1.855901 0 47
leadingEdge
-1: GNLY,NKG7,FGFBP2,CST7,PRF1,CTSW,...
+1: GNLY,NKG7,CTSW,FGFBP2,CST7,PRF1,...
2: CCL5,GZMH,IL32,LYAR,CD2,LINC01871,...
-3: HLA-DRA,HLA-DRB1,HLA-DQB1,HLA-DPA1,HLA-DMA,HLA-DRB5,...
-4: COTL1,FTH1,AIF1,LST1,SAT1,SPI1,...
-5: TMEM123,RPS13,RPL22,RPS28,RPL35A,RPL36,...
-6: S100A9,S100A8,LYZ,FCN1,TKT,VCAN,...
-7: CD37,RPS11,MS4A1,CD52,BANK1,TNFRSF13C,...
+3: HLA-DRA,HLA-DRB1,HLA-DQB1,HLA-DPA1,HLA-DPB1,HLA-DMA,...
+4: RPS28,TMEM123,RPL35A,RPS13,RPL9,RPS12,...
+5: COTL1,FTH1,AIF1,LST1,SAT1,NAP1L1,...
+6: S100A9,S100A8,LYZ,FCN1,TKT,MNDA,...
+7: CD37,CD52,MS4A1,BANK1,CD79B,TNFRSF13C,...
$`8`
- pathway pval padj ES NES nMoreExtreme size
-1: ncMono 0.0021600605 0.003240091 -0.7537958 -1.411206 19 49
-2: NK cell 0.0006480181 0.001166433 -0.7784508 -1.457363 5 49
-3: B cell 0.0004329004 0.001166433 -0.7863661 -1.466871 3 47
-4: cDC 0.0005745145 0.001166433 -0.8884593 -1.499586 4 17
-5: cMono 0.0001082251 0.000487013 -0.8319138 -1.551835 0 47
-6: CD4 T cell 0.0001077702 0.000487013 -0.9066494 -1.701390 0 50
+ pathway pval padj ES NES nMoreExtreme size
+1: Plasma cell 0.0497362472 0.0639466035 0.6759316 1.456101 65 24
+2: NK cell 0.0014337708 0.0021506562 -0.7686920 -1.449205 12 49
+3: ncMono 0.0014337708 0.0021506562 -0.7689308 -1.449655 12 49
+4: B cell 0.0004431642 0.0013294926 -0.7964359 -1.495521 3 47
+5: cDC 0.0006997901 0.0015745276 -0.8968690 -1.514856 5 17
+6: cMono 0.0001107910 0.0004985597 -0.8330905 -1.564350 0 47
+7: CD4 T cell 0.0001100837 0.0004985597 -0.9094132 -1.719188 0 50
leadingEdge
-1: S100A4,S100A11,AIF1,IFITM2,CEBPB,SERPINA1,...
+1: JCHAIN,MZB1,DAD1,DERL3,TNFRSF17,MYDGF,...
2: ITGB2,NKG7,GNLY,MYO1F,IFITM1,JAK1,...
-3: CD52,RPS23,RPL13A,RPS11,RPL12,FAU,...
-4: HLA-DRA,HLA-DRB1,HLA-DPB1,HLA-DPA1,HLA-DQB1,HLA-DMA,...
-5: JUND,S100A6,NFKBIA,TYROBP,LYZ,FOS,...
-6: RPL34,RPS13,RPL13,EEF1A1,RPS3A,RPL32,...
+3: S100A4,S100A11,AIF1,IFITM2,CEBPB,SERPINA1,...
+4: CD52,RPS23,RPL13A,RPS11,RPL12,FAU,...
+5: HLA-DRA,HLA-DRB1,HLA-DPB1,HLA-DPA1,HLA-DQB1,HLA-DMA,...
+6: JUND,S100A6,TYROBP,NFKBIA,LYZ,FOS,...
+7: RPL34,EEF1A1,RPL13,RPS13,RPS3A,RPS6,...
$`9`
- pathway pval padj ES NES nMoreExtreme size
-1: ncMono 0.0001191611 0.001072450 0.9705242 1.879820 0 49
-2: cDC 0.0061555680 0.011080022 0.8911415 1.525520 43 17
-3: cMono 0.0129496403 0.016649538 0.7656658 1.476902 107 47
-4: Plasma cell 0.0330511890 0.037182588 -0.7002547 -1.547523 81 24
-5: NK cell 0.0105590062 0.015838509 -0.6315449 -1.603456 16 49
-6: CD8 T cell 0.0007165890 0.001612325 -0.8974765 -1.869886 1 18
-7: CD4 T cell 0.0006422608 0.001612325 -0.8507977 -2.161552 0 50
-8: B cell 0.0006016847 0.001612325 -0.8721690 -2.198723 0 47
- leadingEdge
-1: AIF1,LST1,COTL1,FCER1G,PSAP,FCGR3A,...
-2: HLA-DPA1,HLA-DRA,HLA-DPB1,HLA-DRB1,HLA-DRB5,HLA-DMA,...
-3: LYZ,TYROBP,S100A6,FCN1,TKT,S100A9,...
-4: ISG20,CYCS,FKBP11,PEBP1,JCHAIN,MZB1,...
-5: CST7,IFITM1,GZMM,CCL4,CD247,HOPX,...
-6: CCL5,IL32,CD3D,GZMH,CD2,LYAR,...
-7: RPL31,RPS29,IL7R,RPS3,RPS27A,CCR7,...
-8: CXCR4,MS4A1,BANK1,TNFRSF13C,LINC00926,RALGPS2,...
+ pathway pval padj ES NES nMoreExtreme size
+1: ncMono 0.0001131990 0.001018791 0.9741332 1.797890 0 49
+2: cDC 0.0419888030 0.062983204 0.8400218 1.386229 314 17
+3: CD8 T cell 0.0004108463 0.001562500 -0.9139791 -1.881373 0 18
+4: NK cell 0.0008561644 0.001562500 -0.7548756 -1.882005 0 49
+5: B cell 0.0008244023 0.001562500 -0.7643028 -1.891838 0 47
+6: CD4 T cell 0.0008680556 0.001562500 -0.8712990 -2.177877 0 50
+ leadingEdge
+1: LST1,AIF1,COTL1,FCER1G,FCGR3A,IFITM3,...
+2: HLA-DPA1,HLA-DRA,HLA-DPB1,HLA-DRB1,HLA-DRB5,MTMR14,...
+3: CCL5,IL32,GZMH,CD3D,CD2,CD8A,...
+4: NKG7,GNLY,CST7,CTSW,GZMA,CD247,...
+5: CXCR4,MS4A1,BANK1,TNFRSF13C,LINC00926,RPL13A,...
+6: RPL31,LDHB,RPS3,IL7R,RPS29,RPS27A,...
Selecing top significant overlap per cluster, we can now rename the clusters according to the predicted labels. OBS! Be aware that if you have some clusters that have non-significant p-values for all the gene sets, the cluster label will not be very reliable. Also, the gene sets you are using may not cover all the celltypes you have in your dataset and hence predictions may just be the most similar celltype. Also, some of the clusters have very similar p-values to multiple celltypes, for instance the ncMono and cMono celltypes are equally good for some clusters.
@@ -929,93 +932,93 @@$`1`
pathway pval padj ES NES
-1: Neutrophil 0.0001507613 0.01493723 0.9197310 2.010307
-2: CD1C+_B dendritic cell 0.0001589067 0.01493723 0.9293164 1.931839
-3: Stromal cell 0.0013311148 0.05004992 0.8544544 1.696909
+1: Neutrophil 0.0001222195 0.01215255 0.9203456 1.876178
+2: CD1C+_B dendritic cell 0.0001292825 0.01215255 0.9243123 1.809278
+3: Stromal cell 0.0011025358 0.04145535 0.8693509 1.626355
nMoreExtreme size leadingEdge
-1: 0 80 S100A8,S100A9,S100A12,MNDA,S100A11,NAMPT,...
-2: 0 53 S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
-3: 7 38 VIM,TIMP2,BST1,TIMP1,ANPEP,CD44,...
+1: 0 80 S100A8,S100A9,S100A12,MNDA,NAMPT,S100A11,...
+2: 0 54 S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
+3: 7 38 VIM,TIMP2,BST1,TIMP1,CD44,ANPEP,...
$`2`
pathway pval padj ES NES
-1: Follicular B cell 0.006354586 0.05430282 0.8587199 1.627043
-2: Pyramidal cell 0.003853565 0.04168250 -0.9722789 -1.490874
-3: CD4+CD25+ regulatory T cell 0.001541426 0.02414900 -0.9799548 -1.502644
+1: Follicular B cell 0.008464329 0.06630391 0.8526465 1.600418
+2: Pyramidal cell 0.004198321 0.04582724 -0.9744811 -1.516437
+3: CD4+CD25+ regulatory T cell 0.002199120 0.03445289 -0.9799105 -1.524886
nMoreExtreme size leadingEdge
-1: 29 22 MS4A1,CD69,CD22,FCER2,CD40,PAX5,...
-2: 19 6 NRGN,CD3E
-3: 7 6 CD3E,CD3D,CD3G,PTPRC,CD4
+1: 41 22 MS4A1,CD69,CD22,FCER2,CD40,PAX5,...
+2: 20 6 NRGN,CD3E
+3: 10 6 CD3E,CD3D,CD3G,PTPRC,CD4
$`3`
- pathway pval padj ES NES
-1: Neutrophil 0.0001011327 0.007217168 0.8809821 1.569285
-2: CD1C+_B dendritic cell 0.0001033271 0.007217168 0.8836167 1.550651
-3: Monocyte derived dendritic cell 0.0001151676 0.007217168 0.9481164 1.532539
- nMoreExtreme size leadingEdge
-1: 0 80 S100A9,S100A8,S100A11,CD14,LST1,MNDA,...
-2: 0 53 S100A9,LYZ,S100A8,FCN1,VCAN,CD14,...
-3: 0 17 S100A9,S100A8,CST3,CD14,CD33,ITGAX,...
+ pathway pval padj ES NES
+1: Neutrophil 0.0001081315 0.01063709 0.8977016 1.749619
+2: CD1C+_B dendritic cell 0.0001131606 0.01063709 0.8981095 1.699327
+3: Stromal cell 0.0003583801 0.02245849 0.8818002 1.619610
+ nMoreExtreme size leadingEdge
+1: 0 80 S100A9,S100A8,S100A11,LST1,CD14,S100A12,...
+2: 0 54 LYZ,S100A9,S100A8,FCN1,VCAN,CD14,...
+3: 2 38 VIM,CD44,TIMP2,TIMP1,ICAM1,PECAM1,...
$`4`
pathway pval padj ES NES nMoreExtreme
-1: Naive CD8+ T cell 0.0001888218 0.005616299 0.8620656 2.045525 0
-2: Naive CD4+ T cell 0.0002017756 0.005616299 0.9214751 1.879833 0
-3: CD4+ T cell 0.0002022654 0.005616299 0.9193037 1.787130 0
+1: Naive CD8+ T cell 0.0002157497 0.006783575 0.8599144 2.048419 0
+2: Naive CD4+ T cell 0.0002164971 0.006783575 0.9296309 1.895090 0
+3: CD4+ T cell 0.0002150538 0.006783575 0.9271953 1.799035 0
size leadingEdge
-1: 91 LDHB,PIK3IP1,NOSIP,TCF7,RCAN3,NPM1,...
+1: 91 LDHB,PIK3IP1,NOSIP,TCF7,NPM1,RCAN3,...
2: 34 IL7R,NOSIP,TCF7,EEF1B2,RPS5,MAL,...
3: 25 IL7R,LTB,CD3E,CD3D,CD3G,CD2,...
$`5`
- pathway pval padj ES NES
-1: Follicular B cell 0.005346572 0.04188148 0.8501224 1.610208
-2: Hematopoietic precursor cell 0.008534851 0.06171354 -0.9521366 -1.493451
-3: Pyramidal cell 0.003048161 0.03581589 -0.9725160 -1.525417
- nMoreExtreme size leadingEdge
-1: 27 22 MS4A1,CD69,CD22,CD40,FCER2,PAX5,...
-2: 41 6 CD14,PTPRC
-3: 14 6 CD3E,NRGN
+ pathway pval padj ES NES nMoreExtreme
+1: Follicular B cell 0.008289527 0.05993966 0.8517164 1.606149 40
+2: Myoepithelial cell 0.008235294 0.05993966 -0.9398262 -1.486394 41
+3: Pyramidal cell 0.002341463 0.03160284 -0.9730353 -1.502327 11
+ size leadingEdge
+1: 22 MS4A1,CD69,CD22,CD40,FCER2,PAX5,...
+2: 7 ITGB1,BHLHE40,CD44
+3: 6 CD3E,NRGN
$`6`
pathway pval padj ES
-1: CD4+ cytotoxic T cell 0.0001908761 0.007875995 0.8929282
-2: Natural killer cell 0.0003821899 0.009483454 0.7967208
-3: Effector CD8+ memory T (Tem) cell 0.0003824092 0.009483454 0.7969411
+1: CD4+ cytotoxic T cell 0.0001825484 0.008283763 0.8850534
+2: Natural killer cell 0.0001830831 0.008283763 0.8009472
+3: Effector CD8+ memory T (Tem) cell 0.0003665689 0.011485826 0.7818876
NES nMoreExtreme size leadingEdge
-1: 2.063730 0 86 CCL5,NKG7,GZMH,GNLY,CST7,GZMA,...
-2: 1.835585 1 84 NKG7,GNLY,CD3D,CD3E,GZMA,CD3G,...
-3: 1.824241 1 79 GZMH,GNLY,ARL4C,GZMB,FGFBP2,KLRD1,...
+1: 2.020483 0 86 CCL5,NKG7,GNLY,GZMH,CST7,GZMA,...
+2: 1.824333 0 84 NKG7,GNLY,CD3D,CD3E,GZMA,CD3G,...
+3: 1.765723 1 79 GNLY,GZMH,ARL4C,GZMB,FGFBP2,KLRD1,...
$`7`
pathway pval padj ES NES
-1: CD4+ cytotoxic T cell 0.0002165909 0.01025753 0.9480244 2.205220
-2: Effector CD8+ memory T (Tem) cell 0.0002165909 0.01025753 0.8968211 2.068348
-3: Natural killer cell 0.0002182453 0.01025753 0.8507701 1.972715
+1: CD4+ cytotoxic T cell 0.0002382087 0.01130895 0.9485749 2.191249
+2: Effector CD8+ memory T (Tem) cell 0.0002406160 0.01130895 0.8946982 2.041811
+3: Natural killer cell 0.0002387205 0.01130895 0.8572499 1.974925
nMoreExtreme size leadingEdge
-1: 0 86 GNLY,NKG7,GZMB,FGFBP2,CCL5,CST7,...
+1: 0 86 GNLY,NKG7,CCL5,GZMB,CTSW,FGFBP2,...
2: 0 79 GNLY,GZMB,FGFBP2,KLRD1,SPON2,GZMH,...
-3: 0 84 GNLY,NKG7,GZMB,GZMA,CD247,KLRD1,...
+3: 0 84 GNLY,NKG7,GZMB,CD247,GZMA,KLRD1,...
$`8`
- pathway pval padj ES NES nMoreExtreme
-1: Megakaryocyte 0.002577320 0.08490323 0.7934901 1.757021 2
-2: Neutrophil 0.008846794 0.11600655 -0.6842598 -1.340588 84
-3: Mesenchymal cell 0.009494346 0.11600655 -0.7144618 -1.363128 88
- size leadingEdge
-1: 25 PPBP,PF4,GP9,ITGA2B,CD9,RASGRP2,...
-2: 80 PTPRC,ITGB2,S100A11,CD44,IFITM2,S100A12,...
-3: 58 S100A4,PTPRC,VIM,CD44,ZEB2,CTSC,...
+ pathway pval padj ES NES nMoreExtreme
+1: Megakaryocyte 0.008771930 0.1649123 0.8128385 1.763957 10
+2: Eosinophil 0.007063238 0.1480465 -0.7453288 -1.396081 63
+3: Natural killer cell 0.003492433 0.1480465 -0.7084403 -1.396899 32
+ size leadingEdge
+1: 25 PPBP,PF4,GP9,ITGA2B,CD9,RASGRP2,...
+2: 47 CD52,PTPRC,CD48,CD44,CD53,CD69,...
+3: 84 PTPRC,NKG7,GNLY,CD69,CD81,FCGR3A,...
$`9`
- pathway pval padj ES NES
-1: Mesenchymal cell 0.0001175917 0.02210724 0.8495970 1.678997
-2: Stromal cell 0.0007528231 0.04569762 0.8602790 1.630578
-3: Endometrial stem cell 0.0029594138 0.06821588 0.9013667 1.560572
- nMoreExtreme size leadingEdge
-1: 0 58 COTL1,S100A4,VIM,CTSC,HES4,ZEB2,...
-2: 5 38 VIM,PECAM1,TIMP1,CD44,TIMP2,ICAM3,...
-3: 20 18 PECAM1,CD44,PTPRC,ITGA4,ITGB1,ENG,...
+ pathway pval padj ES NES nMoreExtreme
+1: Mesenchymal cell 0.0001106929 0.02081027 0.8631721 1.606935 0
+2: Stromal cell 0.0009342520 0.04648863 0.8552856 1.544942 7
+3: Hemangioblast 0.0003017502 0.02836451 0.9907663 1.516461 1
+ size leadingEdge
+1: 58 COTL1,S100A4,CTSC,HES4,VIM,ZEB2,...
+2: 38 PECAM1,TIMP1,VIM,TIMP2,PTPRC,CD44,...
+3: 8 PECAM1,CD34
#CT_GSEA8:
@@ -1435,7 +1438,7 @@Downloading https://export.uppmax.uu.se/naiss2023-23-3/workshops/workshop-scrnaseq/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_filtered_feature_bc_matrix.tar.gz to data/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_filtered_feature_bc_matrix.tar.gz
-Uncompressing data/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_filtered_feature_bc_matrix.tar.gz
-Downloading https://export.uppmax.uu.se/naiss2023-23-3/workshops/workshop-scrnaseq/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_spatial.tar.gz to data/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_spatial.tar.gz
+Uncompressing data/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_filtered_feature_bc_matrix.tar.gz
Uncompressing data/spatial/visium/Anterior/V1_Mouse_Brain_Sagittal_Anterior_spatial.tar.gz
-Downloading https://export.uppmax.uu.se/naiss2023-23-3/workshops/workshop-scrnaseq/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_filtered_feature_bc_matrix.tar.gz to data/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_filtered_feature_bc_matrix.tar.gz
Uncompressing data/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_filtered_feature_bc_matrix.tar.gz
-Downloading https://export.uppmax.uu.se/naiss2023-23-3/workshops/workshop-scrnaseq/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_spatial.tar.gz to data/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_spatial.tar.gz
Uncompressing data/spatial/visium/Posterior/V1_Mouse_Brain_Sagittal_Posterior_spatial.tar.gz
used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 10071341 537.9 14514548 775.2 14514548 775.2
-Vcells 191849982 1463.7 373707381 2851.2 373703568 2851.2
+Ncells 10077614 538.3 14514560 775.2 14514560 775.2
+Vcells 191871231 1463.9 373705667 2851.2 373705055 2851.2
Then we run dimensionality reduction and clustering as before.
@@ -748,7 +749,7 @@ used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 10176004 543.5 18544292 990.4 18544292 990.4
-Vcells 577825608 4408.5 833436874 6358.7 578228452 4411.6
+ used (Mb) gc trigger (Mb) max used (Mb)
+Ncells 10176084 543.5 18536281 990.0 18536281 990
+Vcells 576826421 4400.9 831998051 6347.7 577229270 4404
# check number of cells per subclass
ar_sce$subclass <- sub("/", "_", sub(" ", "_", ar_sce$subclass))
@@ -1310,7 +1311,7 @@ Published with Quarto v1.3.450
@@ -378,7 +383,7 @@
@@ -486,7 +491,7 @@
@@ -852,7 +857,7 @@
regressing out ['total_counts', 'pct_counts_mt']
sparse input is densified and may lead to high memory use
- finished (0:00:46)
+ finished (0:00:50)
computing neighbors
finished: added to `.uns['neighbors']`
`.obsp['distances']`, distances for each pair of neighbors
- `.obsp['connectivities']`, weighted adjacency matrix (0:00:01)
+ `.obsp['connectivities']`, weighted adjacency matrix (0:00:00)
computing UMAP
finished: added
- 'X_umap', UMAP coordinates (adata.obsm) (0:00:11)
+ 'X_umap', UMAP coordinates (adata.obsm) (0:00:10)
computing tSNE
using sklearn.manifold.TSNE
finished: added
- 'X_tsne', tSNE coordinates (adata.obsm) (0:00:13)
+ 'X_tsne', tSNE coordinates (adata.obsm) (0:00:12)
We can now plot the unintegrated and the integrated space reduced dimensions.
@@ -952,9 +957,9 @@<matplotlib.legend.Legend at 0x7fff4670faf0>
+<matplotlib.legend.Legend at 0x7fff4680fbe0>
tmp = pd.crosstab(adata.obs['sample'],adata.obs['leiden_0.6'], normalize='index')
tmp.plot.bar(stacked=True).legend(bbox_to_anchor=(1.4, 1), loc='upper right')
<matplotlib.legend.Legend at 0x7fff46ac6dd0>
+<matplotlib.legend.Legend at 0x7fff46bb3be0>
ranking genes
- finished (0:00:12)
+ finished (0:00:09)
ranking genes
- finished (0:00:31)
+ finished (0:00:20)
tmp = pd.crosstab(adata.obs['louvain_0.6'],adata.obs['predicted'], normalize='index')
tmp.plot.bar(stacked=True).legend(bbox_to_anchor=(1.8, 1),loc='upper right')
<matplotlib.legend.Legend at 0x7fff4ef2ba30>
+<matplotlib.legend.Legend at 0x7fff4ec62b60>
running ingest
- finished (0:00:22)
+ finished (0:00:20)
tmp = pd.crosstab(adata.obs['louvain_0.6'],adata.obs['louvain'], normalize='index')
tmp.plot.bar(stacked=True).legend(bbox_to_anchor=(1.8, 1),loc='upper right')
<matplotlib.legend.Legend at 0x7fff310cc460>
+<matplotlib.legend.Legend at 0x7fff4e07aa40>
normalizing counts per cell
- finished (0:00:01)
+ finished (0:00:00)
extracting highly variable genes
- finished (0:00:06)
+ finished (0:00:03)
--> added
'highly_variable', boolean vector (adata.var)
'means', float vector (adata.var)
@@ -1442,7 +1447,7 @@
@@ -2054,7 +2059,7 @@ Published with Quarto v1.3.450
16-Jan-2024
+23-Jan-2024
We can now load the expression matrices and merge them into a single object. Each analysis workflow (Seurat, Scater, Scanpy, etc) has its own way of storing data. We will add dataset labels as cell.ids just in case you have overlapping barcodes between the datasets. After that we add a column Chemistry in the metadata for plotting later on.
+We can now merge them objects into a single object. Each analysis workflow (Seurat, Scater, Scanpy, etc) has its own way of storing data. We will add dataset labels as cell.ids just in case you have overlapping barcodes between the datasets. After that we add a column type in the metadata to define covid and ctrl samples.
+But first, we need to create Seurat objects using each of the expression matrices we loaded. We define each sample in the project
slot, so in each object, the sample id can be found in the metadata slot orig.ident
.
sdata.cov1 <- CreateSeuratObject(cov.1, project = "covid_1")
sdata.cov15 <- CreateSeuratObject(cov.15, project = "covid_15")
@@ -366,8 +372,8 @@ gc()
used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 3325459 177.6 4998412 267 4998412 267.0
-Vcells 58182395 443.9 150859912 1151 136166604 1038.9
+Ncells 3325437 177.6 4998403 267 4998403 267.0
+Vcells 58182452 443.9 150860051 1151 136166661 1038.9
Here is how the count matrix and the metadata look like for every cell.
@@ -442,7 +448,7 @@As you can see, there is quite some difference in quality for the 4 datasets, with for instance the covid_15 sample having fewer cells with many detected genes and more mitochondrial content. As the ribosomal proteins are highly expressed they will make up a larger proportion of the transcriptional landscape when fewer of the lowly expressed genes are detected. And we can plot the different QC-measures as scatter plots.
+As you can see, there is quite some difference in quality for the 4 datasets, with for instance the covid_15 and covid_16 samples having fewer cells with many detected genes and more mitochondrial content. As the ribosomal proteins are highly expressed they will make up a larger proportion of the transcriptional landscape when fewer of the lowly expressed genes are detected. We can also plot the different QC-measures as scatter plots.
As the level of expression of mitochondrial and MALAT1 genes are judged as mainly technical, it can be wise to remove them from the dataset before any further analysis.
+As the level of expression of mitochondrial and MALAT1 genes are judged as mainly technical, it can be wise to remove them from the dataset before any further analysis. In this case we will also remove the HB genes.
[1] 18851 7431
+[1] 18854 7431
genes_file <- file.path(path_results, "genes_table.csv")
@@ -634,7 +640,19 @@
+
+
+
+
+
+Discuss
+
+
+
+Here, we can see clearly that we have three males and five females, can you see which samples they are? Do you think this will cause any problems for downstream analysis? Discuss with your group: what would be the best way to deal with this type of sex bias?
+
+
data.filt <- data.filt[, data.filt@meta.data[, DF.name] == "Singlet"]
dim(data.filt)
[1] 18851 7134
+[1] 18854 7134
used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 3414313 182.4 4989403 266.5 4989403 266.5
-Vcells 203222859 1550.5 564336378 4305.6 879335547 6708.8
+Ncells 3414481 182.4 4989417 266.5 4989417 266.5
+Vcells 203242618 1550.7 556191914 4243.5 868979728 6629.8
Let’s plot some marker genes for different cell types onto the embedding.
@@ -561,7 +566,7 @@16-Jan-2024
+19-Jan-2024
saveRDS(alldata, "data/covid/results/seurat_covid_qc_dr_int_cl.rds")
-Now, we can select one of our clustering methods and compare the proportion of samples across the clusters.
Select the “CCA_snn_res.0.5” and plot proportion of samples per cluster and also proportion covid vs ctrl.
0 1 2 3 4 5 6 7 8
-2056 1259 1113 646 535 494 365 337 329
+2063 1297 1073 642 546 489 368 336 320
covid_1 covid_15 covid_16 covid_17 ctrl_13 ctrl_14 ctrl_19 ctrl_5
- 95 32 37 173 64 62 37 146
+ 93 32 37 173 62 62 37 146
Coefficient: bulk.labelsCtrl
- logFC logCPM F PValue FDR
-S100A8 -2.672605 6.972711 37.41996 6.779653e-06 0.01083389
-S100A9 -2.512717 7.374885 27.28588 5.193871e-05 0.04149903
-STAG3 -3.378653 7.540873 24.35275 8.987020e-05 0.04787086
-PIM3 -1.412489 7.839512 17.02383 6.030641e-04 0.23537510
-IGHA1 -2.676072 6.965149 16.09405 7.364678e-04 0.23537510
-DYNC1H1 1.279395 6.711434 12.94684 1.976508e-03 0.52641010
-PHACTR1 -1.207474 7.908323 11.47741 3.176723e-03 0.67568316
-CCR7 -1.301642 8.017766 11.28727 3.382644e-03 0.67568316
-WDFY2 1.172984 7.133247 10.76672 4.049332e-03 0.69392707
-MOB3A -1.128665 7.131236 10.56187 4.342472e-03 0.69392707
+ logFC logCPM F PValue FDR
+S100A8 -2.769215 6.963840 45.76310 1.792203e-06 0.002996563
+S100A9 -2.605746 7.463864 29.05267 3.622977e-05 0.030288086
+STAG3 -3.130834 7.358135 20.80773 2.141285e-04 0.119340964
+IGHA1 -2.777404 6.965359 18.84381 3.484837e-04 0.145666204
+DYNC1H1 1.371425 6.575657 14.60978 1.187609e-03 0.397136505
+PIM3 -1.391713 7.788553 12.91552 1.991325e-03 0.499573279
+TLE1 -1.135713 7.356197 12.76593 2.091515e-03 0.499573279
+TRAF3IP3 1.206566 7.489238 11.85600 2.799146e-03 0.585021456
+WDFY2 1.178937 7.063276 11.38622 3.275591e-03 0.608532060
+AHNAK 1.163878 7.833990 11.02406 3.680067e-03 0.615307195
As you can see, we have very few significant genes. Since we only have 4 vs 4 samples, we should not expect too many genes with this method.
@@ -1050,33 +1055,32 @@An object of class Seurat
-18851 features across 1126 samples within 1 assay
-Active assay: RNA (18851 features, 2000 variable features)
+18854 features across 1126 samples within 1 assay
+Active assay: RNA (18854 features, 2000 variable features)
6 dimensional reductions calculated: umap, tsne, umap_raw, pca_harmony, harmony, umap_harmony
● Matching reference with new dataset...
─ 2000 features present in reference loadings
- ─ 1782 features shared between reference and new dataset
- ─ 89.1% of features in the reference are present in new dataset
+ ─ 1783 features shared between reference and new dataset
+ ─ 89.15% of features in the reference are present in new dataset
● Aligning new data to reference...
● Classifying cells...
DONE!
@@ -472,7 +477,7 @@ 0 1 2 3 4 5 6 7 8
-3349 4118 3271 2504 2061 2581 2426 3487 2355
+3307 4102 3289 2478 2017 2522 2483 3513 2298
$`0`
- pathway pval padj ES NES nMoreExtreme size
-1: cMono 0.00009999 0.000299970 0.9594422 2.067666 0 48
-2: ncMono 0.00009999 0.000299970 0.8385199 1.797428 0 43
-3: cDC 0.00009999 0.000299970 0.8394045 1.795307 0 41
-4: pDC 0.00180415 0.004059336 0.7492218 1.535717 17 21
-5: NK cell 0.02711970 0.048815461 0.7545862 1.436992 260 10
-6: B cell 0.06447382 0.096710725 0.6666689 1.329777 638 15
+ pathway pval padj ES NES nMoreExtreme size
+1: cMono 0.000099990 0.000299970 0.9596774 2.060568 0 48
+2: cDC 0.000099990 0.000299970 0.8397658 1.790162 0 41
+3: ncMono 0.000099990 0.000299970 0.8371549 1.787799 0 43
+4: pDC 0.001203369 0.002707581 0.7436632 1.519896 11 21
+5: NK cell 0.029631165 0.053336096 0.7493872 1.424591 285 10
+6: B cell 0.059484067 0.089226100 0.6673689 1.326559 587 15
leadingEdge
1: S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
-2: CTSS,TYMP,CST3,S100A11,AIF1,SERPINA1,...
-3: LYZ,GRN,TYMP,CST3,AIF1,LGALS2,...
+2: LYZ,GRN,TYMP,CST3,AIF1,LGALS2,...
+3: CTSS,TYMP,CST3,S100A11,AIF1,SERPINA1,...
4: GRN,MS4A6A,CST3,MPEG1,CTSB,TGFBI,...
5: TYROBP,FCER1G,SRGN,CCL3,MYO1F,ITGB2,...
6: NCF1,LY86,MARCH1,POU2F2,HLA-DMB,HLA-DRB5,...
$`1`
pathway pval padj ES NES nMoreExtreme size
-1: NK cell 0.0000999900 0.0004007213 0.9459800 2.369826 0 48
-2: CD8 T cell 0.0001001803 0.0004007213 0.9230826 2.201075 0 25
-3: ncMono 0.0008014655 0.0016029311 0.9101411 1.755775 6 6
-4: pDC 0.0078939059 0.0126302494 0.7711439 1.640731 74 10
-5: Plasma cell 0.0007002101 0.0016029311 0.6711407 1.625909 6 30
- leadingEdge
-1: GNLY,GZMB,FGFBP2,PRF1,NKG7,SPON2,...
-2: GNLY,GZMB,FGFBP2,PRF1,NKG7,CTSW,...
-3: FCGR3A,IFITM2,RHOC
-4: GZMB,C12orf75,HSP90B1,ALOX5AP,PLAC8,RRBP1,...
-5: FKBP11,CD38,SDF2L1,PRDM1,PPIB,SLAMF7,...
+1: NK cell 0.0000999900 0.0004014049 0.9481456 2.370524 0 48
+2: CD8 T cell 0.0001003512 0.0004014049 0.9281929 2.209379 0 25
+3: ncMono 0.0004561524 0.0012164063 0.9189116 1.778055 3 6
+4: pDC 0.0096296296 0.0154074074 0.7758141 1.647353 90 10
+5: Plasma cell 0.0013024747 0.0026049494 0.6721222 1.626799 12 30
+ leadingEdge
+1: GNLY,GZMB,FGFBP2,PRF1,NKG7,SPON2,...
+2: GNLY,GZMB,FGFBP2,PRF1,NKG7,CTSW,...
+3: FCGR3A,IFITM2,RHOC
+4: GZMB,C12orf75,HSP90B1,ALOX5AP,PLAC8,RRBP1
+5: FKBP11,PRDM1,CD38,SDF2L1,PPIB,SLAMF7,...
$`2`
pathway pval padj ES NES nMoreExtreme size
-1: CD8 T cell 0.0001001101 0.0003503854 0.9406368 2.161149 0 29
-2: NK cell 0.0001000500 0.0003503854 0.8208967 1.898566 0 32
-3: CD4 T cell 0.0014347202 0.0033476805 0.8706473 1.681457 12 7
-4: Plasma cell 0.0744595677 0.1042433947 0.5638039 1.298014 743 30
+1: CD8 T cell 0.0001000801 0.0003502802 0.9332541 2.141759 0 29
+2: NK cell 0.0001000600 0.0003502802 0.8217604 1.895062 0 31
+3: CD4 T cell 0.0019867550 0.0046357616 0.8693316 1.678458 17 7
+4: Plasma cell 0.0817572301 0.1144601221 0.5564210 1.279938 816 30
leadingEdge
-1: CD3D,CD8A,CD3G,CCL5,CD8B,GZMH,...
-2: CCL5,GZMA,CCL4,NKG7,GZMM,CST7,...
+1: CD3D,CD8A,CD3G,CD8B,CCL5,GZMH,...
+2: CCL5,GZMA,CCL4,GZMM,NKG7,CST7,...
3: CD3D,CD3G,CD3E,IL7R,PIK3IP1,TCF7
4: FKBP11,PRDM1,PEBP1,PPIB,SEC11C,SUB1,...
$`3`
pathway pval padj ES NES nMoreExtreme size
-1: B cell 0.0000999900 0.0002706726 0.9072478 1.989836 0 46
-2: cDC 0.0001015022 0.0002706726 0.8950426 1.806256 0 14
-3: pDC 0.0001008878 0.0002706726 0.8292186 1.700818 0 17
-4: Plasma cell 0.0348925962 0.0558281540 0.7900880 1.456388 319 7
+1: B cell 0.0000999900 0.0004060914 0.9070112 2.004342 0 46
+2: cDC 0.0001015228 0.0004060914 0.8951817 1.814950 0 14
+3: pDC 0.0004026170 0.0010736454 0.7937887 1.648175 3 18
+4: Plasma cell 0.0800554312 0.1280886899 0.7211352 1.360348 750 8
leadingEdge
1: CD79A,LINC00926,TCL1A,MS4A1,TNFRSF13C,CD79B,...
-2: CD74,HLA-DQB1,HLA-DRA,HLA-DPB1,HLA-DRB1,HLA-DQA1,...
+2: CD74,HLA-DQB1,HLA-DRA,HLA-DRB1,HLA-DPB1,HLA-DQA1,...
3: CD74,BCL11A,TCF4,IRF8,HERPUD1,TSPAN13,...
-4: PLPP5,ISG20,HERPUD1,MZB1,ITM2C
+4: PLPP5,ISG20,HERPUD1,MZB1,ITM2C,DERL3
$`4`
pathway pval padj ES NES nMoreExtreme size
-1: CD4 T cell 0.0001015744 0.0003199659 0.9121965 1.771474 0 14
-2: CD8 T cell 0.0001066553 0.0003199659 0.9014219 1.638647 0 8
+1: CD4 T cell 0.0001014610 0.0006087662 0.9093092 1.771592 0 14
+2: CD8 T cell 0.0007438104 0.0022314313 0.8911450 1.626159 6 8
leadingEdge
1: IL7R,LTB,LDHB,MAL,RCAN3,NOSIP,...
2: CD3D,IL32,CD3G,CD2,CD3E,CD8B
$`5`
pathway pval padj ES NES nMoreExtreme size
-1: B cell 0.07818977 0.2503001 0.8293407 1.392212 678 5
-2: pDC 0.04285714 0.2503001 0.7176562 1.385862 425 18
-3: ncMono 0.08343337 0.2503001 0.6474875 1.279034 833 28
+1: pDC 0.03817025 0.2740774 0.7278455 1.398044 377 17
+2: ncMono 0.06090609 0.2740774 0.6549736 1.297265 608 30
leadingEdge
-1: PDLIM1,HLA-DRB5,STX7
-2: PTCRA,TXN,C12orf75,CST3,CTSB,APP,...
-3: OAZ1,TIMP1,IFITM3,FKBP1A,CD68,CST3,...
+1: PTCRA,TXN,C12orf75,CST3,APP,CTSB,...
+2: OAZ1,TIMP1,IFITM3,FKBP1A,CD68,CST3,...
$`6`
pathway pval padj ES NES nMoreExtreme size
-1: B cell 0.0000999900 0.0005417852 0.8919905 1.838712 0 45
-2: cDC 0.0002031694 0.0005417852 0.8894057 1.705469 1 14
-3: pDC 0.0002015316 0.0005417852 0.8313241 1.622237 1 17
-4: Plasma cell 0.0232629013 0.0281224853 0.7396460 1.418299 228 14
+1: B cell 0.0000999900 0.0004067521 0.8905126 1.833414 0 45
+2: cDC 0.0001016880 0.0004067521 0.8877832 1.700394 0 14
+3: pDC 0.0003024803 0.0008066142 0.8341772 1.624004 2 17
+4: Plasma cell 0.0277580792 0.0341582581 0.7291313 1.403876 273 15
leadingEdge
1: CD79A,MS4A1,BANK1,HLA-DQA1,CD74,TNFRSF13C,...
2: HLA-DQA1,CD74,HLA-DRA,HLA-DPB1,HLA-DQB1,HLA-DPA1,...
-3: CD74,JCHAIN,SPIB,TCF4,CCDC50,HERPUD1,...
-4: JCHAIN,HERPUD1,ISG20,PEBP1,MZB1,ITM2C
+3: CD74,JCHAIN,SPIB,TCF4,HERPUD1,CCDC50,...
+4: JCHAIN,HERPUD1,ISG20,ITM2C,PEBP1,MZB1
$`7`
pathway pval padj ES NES nMoreExtreme size
-1: ncMono 0.00009999 0.0002666667 0.9644737 2.033813 0 49
-2: cMono 0.00010000 0.0002666667 0.8854337 1.838288 0 36
-3: cDC 0.00009999 0.0002666667 0.8309648 1.730082 0 38
-4: NK cell 0.01025485 0.0205096964 0.7621593 1.478759 100 14
-5: pDC 0.02631313 0.0421010019 0.7165790 1.398343 259 15
-6: B cell 0.05732420 0.0764322654 0.6694322 1.321810 568 17
+1: ncMono 0.00009999 0.0002667734 0.9653377 2.038133 0 49
+2: cMono 0.00010004 0.0002667734 0.8842478 1.838505 0 36
+3: cDC 0.00010002 0.0002667734 0.8287084 1.729668 0 38
+4: NK cell 0.00700721 0.0140144206 0.7660007 1.492316 68 14
+5: pDC 0.02330058 0.0372809239 0.7210229 1.413360 229 15
+6: B cell 0.05925627 0.0790083644 0.6660721 1.322621 587 17
leadingEdge
1: CDKN1C,LST1,FCGR3A,MS4A7,AIF1,COTL1,...
2: LST1,AIF1,COTL1,SERPINA1,FCER1G,CST3,...
@@ -665,10 +668,10 @@
$`0`
pathway pval padj ES NES nMoreExtreme size
-1: Neutrophil 9.999e-05 0.002274773 0.8596747 1.768180 0 22
-2: Monocyte 9.999e-05 0.002274773 0.8152552 1.737522 0 40
-3: Eosinophil 9.999e-05 0.002274773 0.8683785 1.723714 0 13
+1: Neutrophil 9.999e-05 0.001819818 0.8582790 1.761773 0 22
+2: Monocyte 9.999e-05 0.001819818 0.8133774 1.731423 0 40
+3: Eosinophil 9.999e-05 0.001819818 0.8660814 1.711202 0 13
leadingEdge
1: S100A8,S100A9,CD14,CSF3R,S100A6,PLAUR,...
2: S100A8,S100A9,LYZ,S100A12,VCAN,FCN1,...
@@ -934,19 +937,19 @@
+1: 0 12 CCR7,TCF7,IL7R,LEF1,TSHZ2,RCAN3,...
+2: 0 15 CCR7,TCF7,LEF1,TSHZ2,RCAN3,MAL,...
+3: 0 10 CCR7,TCF7,LEF1,LTB,TSHZ2,MAL,...
#CT_GSEA8:
@@ -1386,7 +1389,7 @@suppressPackageStartupMessages({
- library(Seurat)
- library(plotly)
- options(rgl.printRglwidget = TRUE)
- library(Matrix)
- library(sparseMatrixStats)
- library(slingshot)
- library(tradeSeq)
- library(patchwork)
+ library(Seurat)
+ library(plotly)
+ options(rgl.printRglwidget = TRUE)
+ library(Matrix)
+ library(sparseMatrixStats)
+ library(slingshot)
+ library(tradeSeq)
+ library(patchwork)
})
# Define some color palette
@@ -285,11 +290,11 @@
# Add graph to the base R graphics plot
draw_graph <- function(layout, graph, lwd = 0.2, col = "grey") {
- res <- rep(x = 1:(length(graph@p) - 1), times = (graph@p[-1] - graph@p[-length(graph@p)]))
- segments(
- x0 = layout[graph@i + 1, 1], x1 = layout[res, 1],
- y0 = layout[graph@i + 1, 2], y1 = layout[res, 2], lwd = lwd, col = col
- )
+ res <- rep(x = 1:(length(graph@p) - 1), times = (graph@p[-1] - graph@p[-length(graph@p)]))
+ segments(
+ x0 = layout[graph@i + 1, 1], x1 = layout[res, 1],
+ y0 = layout[graph@i + 1, 2], y1 = layout[res, 2], lwd = lwd, col = col
+ )
}
# Define curves
curves <- as.SlingshotDataSet(getCurves(
- data = lineages,
- thresh = 1e-1,
- stretch = 1e-1,
- allow.breaks = F,
- approx_points = 100
+ data = lineages,
+ thresh = 1e-1,
+ stretch = 1e-1,
+ allow.breaks = F,
+ approx_points = 100
))
curves
# Plots
{
- plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], pch = 16)
- lines(curves, lwd = 2, col = "black")
- text(centroids2d, labels = rownames(centroids2d), cex = 1, font = 2)
+ plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], pch = 16)
+ lines(curves, lwd = 2, col = "black")
+ text(centroids2d, labels = rownames(centroids2d), cex = 1, font = 2)
}
sel_cells <- split(colnames(obj@assays$RNA@data), obj$clusters_use)
sel_cells <- unlist(lapply(sel_cells, function(x) {
- set.seed(1)
- return(sample(x, 20))
+ set.seed(1)
+ return(sample(x, 20))
}))
gv <- as.data.frame(na.omit(scran::modelGeneVar(obj@assays$RNA@data[, sel_cells])))
@@ -648,11 +653,11 @@
sceGAM <- fitGAM(
- counts = drop0(obj@assays$RNA@data[sel_genes, sel_cells]),
- pseudotime = pseudotime[sel_cells, ],
- cellWeights = cellWeights[sel_cells, ],
- nknots = 5, verbose = T, parallel = T, sce = TRUE,
- BPPARAM = BiocParallel::MulticoreParam()
+ counts = drop0(obj@assays$RNA@data[sel_genes, sel_cells]),
+ pseudotime = pseudotime[sel_cells, ],
+ cellWeights = cellWeights[sel_cells, ],
+ nknots = 5, verbose = T, parallel = T, sce = TRUE,
+ BPPARAM = BiocParallel::MulticoreParam()
)
Download the precomputed file.
@@ -691,15 +696,15 @@lc <- sapply(lineages@lineages, function(x) {
- rev(x)[1]
+ rev(x)[1]
})
names(lc) <- gsub("Lineage", "L", names(lc))
{
- plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], pch = 16)
- lines(curves, lwd = 2, col = "black")
- points(centroids2d[lc, ], col = "black", pch = 16, cex = 4)
- text(centroids2d[lc, ], labels = names(lc), cex = 1, font = 2, col = "white")
+ plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], pch = 16)
+ lines(curves, lwd = 2, col = "black")
+ points(centroids2d[lc, ], col = "black", pch = 16, cex = 4)
+ text(centroids2d[lc, ], labels = names(lc), cex = 1, font = 2, col = "white")
}
par(mfrow = c(4, 4), mar = c(.1, .1, 2, 1))
{
- plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], cex = .5, pch = 16, axes = F, xlab = "", ylab = "")
- lines(curves, lwd = 2, col = "black")
- points(centroids2d[lc, ], col = "black", pch = 15, cex = 3, xpd = T)
- text(centroids2d[lc, ], labels = names(lc), cex = 1, font = 2, col = "white", xpd = T)
+ plot(obj@reductions$umap@cell.embeddings, col = pal[obj$clusters_use], cex = .5, pch = 16, axes = F, xlab = "", ylab = "")
+ lines(curves, lwd = 2, col = "black")
+ points(centroids2d[lc, ], col = "black", pch = 15, cex = 3, xpd = T)
+ text(centroids2d[lc, ], labels = names(lc), cex = 1, font = 2, col = "white", xpd = T)
}
vars <- rownames(res[1:15, ])
vars <- na.omit(vars[vars != "NA"])
for (i in vars) {
- x <- drop0(obj@assays$RNA@data)[i, ]
- x <- (x - min(x)) / (max(x) - min(x))
- o <- order(x)
- plot(obj@reductions$umap@cell.embeddings[o, ],
- main = paste0(i), pch = 16, cex = 0.5, axes = F, xlab = "", ylab = "",
- col = colorRampPalette(c("lightgray", "grey60", "navy"))(99)[x[o] * 98 + 1]
- )
+ x <- drop0(obj@assays$RNA@data)[i, ]
+ x <- (x - min(x)) / (max(x) - min(x))
+ o <- order(x)
+ plot(obj@reductions$umap@cell.embeddings[o, ],
+ main = paste0(i), pch = 16, cex = 0.5, axes = F, xlab = "", ylab = "",
+ col = colorRampPalette(c("lightgray", "grey60", "navy"))(99)[x[o] * 98 + 1]
+ )
}
used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 3360689 179.5 5248232 280.3 5248232 280.3
-Vcells 189921766 1449.0 375078860 2861.7 357748466 2729.5
+Ncells 3360672 179.5 5248490 280.3 5248490 280.3
+Vcells 189921808 1449.0 375078910 2861.7 357748714 2729.5
As you can see, the mitochondrial genes are among the top expressed genes. Also the lncRNA gene Bc1 (brain cytoplasmic RNA 1). Also one hemoglobin gene.
@@ -521,8 +526,8 @@ used (Mb) gc trigger (Mb) max used (Mb)
-Ncells 3530604 188.6 5248232 280.3 5248232 280.3
-Vcells 546165895 4167.0 1148293022 8760.8 1147468533 8754.5
+Ncells 3530587 188.6 5248490 280.3 5248490 280.3
+Vcells 546165937 4167.0 1148293145 8760.8 1147467666 8754.5
Then we run dimensionality reduction and clustering as before.
@@ -1257,7 +1262,7 @@