.. _LabelTransfer_integrated_label: 5. LabelTransfer integrated ================================== .. code:: r suppressPackageStartupMessages({ library(reticulate) library(Seurat) library(dplyr) library(ggpubr) library(sceasy) library(future) }) # utilities o<- function(w,h) options(repr.plot.width=w, repr.plot.height=h) manycolors=c('#e6194b', '#3cb44b', '#ffe119', '#4363d8', '#f58231', '#911eb4', '#46f0f0', '#f032e6', '#bcf60c', '#fabebe', '#008080', '#e6beff', '#9a6324', '#fffac8', '#800000', '#aaffc3', '#808000', '#ffd8b1', '#000075', '#808080', '#4f34ff', '#f340F0') covid.color.table= c( 'B'="#FFF3B0", 'Plasma'='#E09F3E', 'T'='#2F6D9D', 'T CD4'='#68BDDF', 'T CD8'='#FF046E', 'CD8 cytotoxic T'='#9D2A2B', 'T cycling'='#ADA7FF', 'Treg'='#493A9D', 'NKT'='#3300FF', 'NK'='#D543FF', 'gdT'='#6A24FF', 'Neu'='#312697', 'macrophage'='#429783', 'Mast'='#FF6B3E', 'cDC1'='#FF8F39', 'cDC2'='#E7FF3F', 'moDC'='#FFBCE1', 'pDC'='#FF72DB', 'DC'='#FF0022', 'Mye'='#19C3BE' ) heca.color.table=c( 'B cell'='#FFF3B0', 'CD8 T cell'='#FF046E', 'Dendritic cell'='#FF0022', 'Macrophage'='#429783', 'Mast cell'='#FF6B3E', 'Megakaryocyte'='gray', 'Monocyte'='#429753', 'Myeloid cell'='#19C3BE', 'NK cell'='#D543FF', 'Neutrophilic granunocyte'='#312697', 'Plasma B cell'='#E09F3E', 'T cell'='#2F6D9D' ) load data ========= load hECA data -------------- .. code:: r # convert h5ad to rds format so that R can read it sceasy::convertFormat('./lungimm_heca.h5ad', from="anndata", to="seurat", outFile='lungimm_heca.rds') .. parsed-literal:: X -> counts Warning message: “Keys should be one or more alphanumeric characters followed by an underscore, setting key from DMAPharmony_bydonor_ to DMAPharmonybydonor_” Warning message: “All keys should be one or more alphanumeric characters followed by an underscore '_', setting key to DMAPharmonybydonor_” Warning message: “Keys should be one or more alphanumeric characters followed by an underscore, setting key from PCAharmony_bydonor_ to PCAharmonybydonor_” Warning message: “All keys should be one or more alphanumeric characters followed by an underscore '_', setting key to PCAharmonybydonor_” .. parsed-literal:: An object of class Seurat 20492 features across 53299 samples within 1 assay Active assay: RNA (20492 features, 0 variable features) 6 dimensional reductions calculated: densmap, densmap_harmonyByDonor, dmap_harmony_bydonor, pca, pca_harmony_bydonor, umap .. code:: r # read saved hECA data heca = readRDS('./lungimm_heca.rds') .. code:: r # create a clean seurat object heca.full = CreateSeuratObject(heca@assays$RNA@data, meta.data = heca@meta.data) heca.full@assays$RNA@data <- heca.full@assays$RNA@counts heca.full[["umap"]] <- CreateDimReducObject(heca@reductions$umap@cell.embeddings, key = "umap_") .. parsed-literal:: Warning message: “No assay specified, setting assay as RNA by default.” .. code:: r # show different batches o(15,5) DimPlot(heca.full, group.by='ann',cols = heca.color.table, split.by = 'study_id', pt.size=0.01, label=T, repel=T) # print study_id unique(heca.full@meta.data$study_id) .. raw:: html
  1. 10.1038/s41591-019-0468-5
  2. 10.1186/s13059-019-1906-x
  3. 10.1038/s41586-020-2157-4
Levels:
  1. '10.1038/s41586-020-2157-4'
  2. '10.1038/s41591-019-0468-5'
  3. '10.1186/s13059-019-1906-x'
.. image:: output_6_1.png :width: 900px :height: 300px .. code:: r #heca1 = subset(heca.full, study_id=='10.1038/s41586-020-2157-4') .. code:: r #heca2 = subset(heca.full, study_id=='10.1186/s13059-019-1906-x') created integrated hECA data ---------------------------- .. code:: r heca.list = SplitObject(heca.full, split.by = 'study_id') .. code:: r heca.list .. parsed-literal:: $`10.1038/s41591-019-0468-5` An object of class Seurat 20492 features across 465 samples within 1 assay Active assay: RNA (20492 features, 0 variable features) 1 dimensional reduction calculated: umap $`10.1186/s13059-019-1906-x` An object of class Seurat 20492 features across 41940 samples within 1 assay Active assay: RNA (20492 features, 0 variable features) 1 dimensional reduction calculated: umap $`10.1038/s41586-020-2157-4` An object of class Seurat 20492 features across 10894 samples within 1 assay Active assay: RNA (20492 features, 0 variable features) 1 dimensional reduction calculated: umap .. code:: r plan("sequential") options(future.globals.maxSize = 1000 * 1024^2*4) plan("multiprocess", workers = 14) int.anchors <- FindIntegrationAnchors(object.list = heca.list, dims = 1:30) plan("sequential") .. parsed-literal:: Warning message: “Strategy 'multiprocess' is deprecated in future (>= 1.20.0). Instead, explicitly specify either 'multisession' or 'multicore'. In the current R session, 'multiprocess' equals 'multicore'.” Computing 2000 integration features No variable features found for object1 in the object.list. Running FindVariableFeatures ... No variable features found for object2 in the object.list. Running FindVariableFeatures ... No variable features found for object3 in the object.list. Running FindVariableFeatures ... Scaling features for provided objects Finding all pairwise anchors Running CCA Merging objects Finding neighborhoods Finding anchors Found 2280 anchors Filtering anchors Retained 228 anchors Running CCA Merging objects Finding neighborhoods Finding anchors Found 2238 anchors Filtering anchors Retained 370 anchors Running CCA Merging objects Finding neighborhoods Finding anchors Found 27018 anchors Filtering anchors Retained 5907 anchors .. code:: r heca.integrated <- IntegrateData(anchorset = int.anchors, dims = 1:30) .. parsed-literal:: Merging dataset 1 into 3 Extracting anchors for merged samples Finding integration vectors Finding integration vector weights Integrating data Merging dataset 3 1 into 2 Extracting anchors for merged samples Finding integration vectors Finding integration vector weights Integrating data .. code:: r #mask horizontal genes x=heca.integrated masked.genes<-c( c(grep("^RPL", rownames(x), value = T),grep("^RPS", rownames(x), value = T)), grep("^MT-", rownames(x), value = T), c(grep("^IFI", rownames(x), value = T),grep("^ISG", rownames(x), value = T)), grep("^SMC[0-9]*", rownames(x), value = T), grep("^MCM[0-9]*", rownames(x), value = T), c(grep("^TUBA", rownames(x), value = T), grep("^TUBB", rownames(x), value = T), grep("^TUBD[0-9]", rownames(x), value = T), grep("^TUBE[0-9]", rownames(x), value = T), grep("^TUBG[0-9]", rownames(x), value = T) ), c(Seurat::cc.genes.updated.2019$s.genes, Seurat::cc.genes.updated.2019$g2m.genes ), c("H1-0","H1-1","H1-10","H1-12P","H1-2","H1-3","H1-4","H1-5","H1-6","H1-7","H1-8", "H1-9P","H2AB1","H2AB2","H2AB3","H2AC1","H2AC10P","H2AC11","H2AC12","H2AC13","H2AC14", "H2AC15","H2AC16","H2AC17","H2AC18","H2AC19","H2AC20","H2AC21","H2AC2P","H2AC3P","H2AC4", "H2AC5P","H2AC6","H2AC7","H2AC8","H2AC9P","H2AJ","H2AL1MP","H2AL1Q","H2AL3", "H2AP","H2AQ1P","H2AW","H2AX","H2AZ1","H2AZ2","MACROH2A1","MACROH2A2","H2BC1","H2BC10", "H2BC11","H2BC12","H2BC13","H2BC14","H2BC15","H2BC16P","H2BC17","H2BC18", "H2BC19P","H2BC20P","H2BC21","H2BC2P","H2BC3","H2BC4","H2BC5","H2BC6","H2BC7","H2BC8", "H2BC9","H2BK1","H2BL1P","H2BN1","H2BC12L","H2BU1","H2BU2P","H2BW1","H2BW2", "H2BW3P","H2BW4P","H3-7","H3-3A","H3-3B","H3-4","H3-5","H3C1","H3C10","H3C11","H3C12", "H3C13","H3C14","H3C15","H3C2","H3C3","H3C4","H3C5P","H3C6","H3C7","H3C8", "H3C9P","H3Y1","H3Y2","CENPA","H4-16","H4C1","H4C10P","H4C11","H4C12","H4C13","H4C14", "H4C15","H4C2","H4C3","H4C4","H4C5","H4C6","H4C7","H4C8","H4C9"), grep("^HIST", rownames(x), value=T) ) goi.int = setdiff( VariableFeatures(heca.integrated), masked.genes) length(goi.int) .. raw:: html 1919 .. code:: r DefaultAssay(heca.integrated) <- "integrated" heca.integrated <- ScaleData(heca.integrated, verbose = FALSE, features = goi.int) heca.integrated <- RunPCA(heca.integrated, npcs = 30, verbose = FALSE, features = goi.int) heca.integrated <- RunUMAP(heca.integrated, reduction = "pca", dims = 1:30, verbose = FALSE) .. parsed-literal:: Warning message: “The default method for RunUMAP has changed from calling Python UMAP via reticulate to the R-native UWOT using the cosine metric To use Python UMAP via reticulate, set umap.method to 'umap-learn' and metric to 'correlation' This message will be shown once per session” .. code:: r # show different batches o(15,5) DimPlot(heca.integrated, group.by='ann',cols = heca.color.table, split.by = 'study_id', pt.size=0.01, label=T, repel=T) # print study_id unique(heca.integrated@meta.data$study_id) .. raw:: html
  1. '10.1038/s41591-019-0468-5'
  2. '10.1186/s13059-019-1906-x'
  3. '10.1038/s41586-020-2157-4'
.. image:: output_16_1.png :width: 900px :height: 300px load COVID data --------------- .. code:: r load("./nCoV.integrated.annotated.rda") .. code:: r o(9,8) DimPlot(immune.combined, group.by='persample_ann', label=T, repel=T, cols=covid.color.table) + ggtitle( "COVID19 lung immune cells")& theme(axis.title = element_blank(), axis.text = element_blank(), axis.ticks=element_blank()) cairo_pdf(filename = 'covid19.umap.pdf', width = 9,height = 8) DimPlot(immune.combined, group.by='persample_ann', label=T, repel=T, cols=covid.color.table) + ggtitle( "COVID19 lung immune cells")& theme(axis.title = element_blank(), axis.text = element_blank(), axis.ticks=element_blank()) dev.off() .. raw:: html png: 2 .. image:: output_19_1.png :width: 540px :height: 480px full batches - integrated data transfer ======================================= .. code:: r plan("sequential") options(future.globals.maxSize = 1000 * 1024^2*4) plan("multiprocess", workers = 14) int.anchors <- FindTransferAnchors(reference = heca.integrated, query = immune.combined, dims = 1:30, reference.reduction = "pca") predictions <- TransferData(anchorset = int.anchors, refdata = heca.integrated$cell_type, dims = 1:30) immune.combined <- AddMetaData(immune.combined, metadata = predictions) plan("sequential") .. parsed-literal:: Projecting cell embeddings Finding neighborhoods Finding anchors Found 7380 anchors Filtering anchors Retained 2966 anchors Finding integration vectors Finding integration vector weights Predicting cell labels .. code:: r o(10,8) DimPlot(immune.combined, group.by='predicted.id', label=T, repel=T, cols=heca.color.table, order='Neutrophilic granunocyte') DimPlot(immune.combined, group.by='persample_ann', label=T, repel=T, cols=covid.color.table) .. image:: output_22_0.png :width: 600px :height: 480px .. image:: output_22_1.png :width: 600px :height: 480px .. code:: r matched <- c( paste('B' , 'B cell', sep="_"), paste('Plasma' , 'Plasma B cell', sep="_"), paste('Plasma' , 'B cell', sep="_"), paste('T' , 'CD8 T cell', sep="_"), paste('T' , 'T cell', sep="_"), paste('T CD4' , 'T cell', sep="_"), paste('T CD8' , 'T cell', sep="_"), paste('T CD8' , 'CD8 T cell', sep="_"), paste('CD8 cytotoxic T' , 'T cell', sep="_"), paste('CD8 cytotoxic T' , 'CD8 T cell', sep="_"), paste('T cycling' , 'T cell', sep="_"), paste('T cycling' , 'CD8 T cell', sep="_"), paste('Treg' , 'T cell', sep="_"), paste('gdT' , 'T cell', sep="_"), paste('NKT' , 'T cell', sep="_"), paste('NK' , 'NK cell', sep="_"), paste('Neu' , 'Neutrophilic granulocyte', sep="_"), paste('macrophage' , 'Macrophage', sep="_"), paste('macrophage' , 'Monocyte', sep="_"), paste('macrophage' , 'Myeloid cell', sep="_"), paste('Mast' , 'Mast cell', sep="_"), paste('cDC1' , 'Dendritic cell', sep="_"), paste('cDC1' , 'Myeloid cell', sep="_"), paste('cDC2' , 'Dendritic cell', sep="_"), paste('cDC2' , 'Myeloid cell', sep="_"), paste('moDC' , 'Dendritic cell', sep="_"), paste('pDC' , 'Dendritic cell', sep="_"), paste('DC' , 'Dendritic cell', sep="_"), paste('Mye' , 'Macrophage', sep="_"), paste('Mye' , 'Mast cell', sep="_"), paste('Mye' , 'Megakaryocyte', sep="_"), paste('Mye' , 'Dendritic cell', sep="_"), paste('Mye' , 'Monocyte', sep="_"), paste('Mye' , 'Neutrophilic granulocyte', sep="_"), paste('Mye' , 'Myeloid cell', sep="_") ) .. code:: r # calculate accuracy meta=immune.combined@meta.data meta = meta[, c('persample_ann','predicted.id')] meta$joint <- paste(meta$persample_ann, meta$predicted.id, sep='_') meta$isMatched <- (meta$joint %in% matched) | (meta$persample_ann == meta$predicted.id) acc = (meta %>% filter(isMatched==T) %>% nrow) / (meta %>% nrow) print( acc ) .. parsed-literal:: [1] 0.9250865 .. code:: r # draw matrix ## create an empty adj matrix rows = as.character( unique(immune.combined@meta.data$persample_ann) ) # from:covid ground-truth cols = as.character( unique(heca.full@meta.data$cell_type) ) # to:predicted to mat <- matrix(0, length(rows), length(cols)) rownames(mat) <- rows colnames(mat) <- cols # get an edge list edge.list = meta %>% count(persample_ann, predicted.id, sort = TRUE) # fill in the edge list for(i in 1:NROW(edge.list)) mat[ edge.list[i,1], edge.list[i,2] ] <- edge.list[i,3] # SEE UPDATE row.order= c('Plasma','B', 'Treg','T cycling','T CD4','T','NKT','gdT','CD8 cytotoxic T', 'T CD8','NK', 'Neu','DC','cDC2','cDC1','macrophage','moDC','pDC','Mast' ) col.order=c('Plasma B cell','B cell', 'T cell','CD8 T cell','NK cell', 'Neutrophilic granulocyte', 'Macrophage','Dendritic cell','Myeloid cell','Mast cell','Monocyte','Megakaryocyte') # row-sum scaling mat = mat/rowSums(mat) mat = mat[row.order,col.order] library(pheatmap) o(5,5) pheatmap(mat, cluster_rows = F, cluster_cols = F, main='hECA integrated reference') .. image:: output_25_0.png :width: 300px :height: 300px .. code:: r library('mclust') adjustedRandIndex(meta$persample_ann, meta$predicted.id) .. parsed-literal:: Package 'mclust' version 5.4.9 Type 'citation("mclust")' for citing this R package in publications. .. raw:: html 0.379420559941594 Annotate data for DEG ===================== .. code:: r o(8,7) DimPlot(heca.integrated, group.by='ann',cols = heca.color.table, pt.size=0.01, label=T, repel=T) .. image:: output_28_0.png :width: 480px :height: 420px .. code:: r o(9,8) DimPlot(heca.integrated, group.by='ann',cols = heca.color.table, pt.size=0.01, label=T, repel=T)& theme(axis.title = element_blank(), axis.text = element_blank(), axis.ticks=element_blank()) cairo_pdf(filename = 'heca.umap.predicted.pdf', width = 9,height = 8) DimPlot(heca.integrated, group.by='ann',cols = heca.color.table, pt.size=0.01, label=T, repel=T)& theme(axis.title = element_blank(), axis.text = element_blank(), axis.ticks=element_blank()) dev.off() .. raw:: html png: 2 .. image:: output_29_1.png :width: 540px :height: 480px .. code:: r DefaultAssay(heca.integrated)<-'integrated' heca.integrated <- FindNeighbors(heca.integrated, reduction = "pca", dims = 1:30) heca.integrated <- FindClusters( heca.integrated, resolution = c(0.5,0.6,0.7,0.8,0.9)) .. parsed-literal:: Computing nearest neighbor graph Computing SNN .. parsed-literal:: Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck Number of nodes: 53299 Number of edges: 1935710 Running Louvain algorithm... Maximum modularity in 10 random starts: 0.9299 Number of communities: 22 Elapsed time: 11 seconds Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck Number of nodes: 53299 Number of edges: 1935710 Running Louvain algorithm... Maximum modularity in 10 random starts: 0.9233 Number of communities: 26 Elapsed time: 10 seconds Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck Number of nodes: 53299 Number of edges: 1935710 Running Louvain algorithm... Maximum modularity in 10 random starts: 0.9177 Number of communities: 27 Elapsed time: 11 seconds Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck Number of nodes: 53299 Number of edges: 1935710 Running Louvain algorithm... Maximum modularity in 10 random starts: 0.9121 Number of communities: 33 Elapsed time: 11 seconds Modularity Optimizer version 1.3.0 by Ludo Waltman and Nees Jan van Eck Number of nodes: 53299 Number of edges: 1935710 Running Louvain algorithm... Maximum modularity in 10 random starts: 0.9072 Number of communities: 34 Elapsed time: 11 seconds .. code:: r DimPlot(heca.integrated, group.by='integrated_snn_res.0.5',label=T) .. image:: output_31_0.png :width: 540px :height: 480px .. code:: r Idents(heca.integrated)<-'integrated_snn_res.0.5' o(15,13) VlnPlot(heca.integrated, features =c( 'CD8A','CD3E','CD69','GZMK','GZMB','TRDC'), pt.size=0.0) .. image:: output_32_0.png :width: 900px :height: 780px .. code:: r o(6*4, 6*2) FeaturePlot(heca.integrated, pt.size=0.01,ncol=4, features = c('CD3E','NKG7','CD4','CD8A', 'CD8B','TRDC')) .. parsed-literal:: Warning message: “Could not find CD4 in the default search locations, found in RNA assay instead” .. image:: output_33_1.png :width: 1440px :height: 720px .. code:: r Idents(heca.integrated)<-'integrated_snn_res.0.5' deg12 = FindMarkers(heca.integrated, only.pos = T, ident.1=12) .. code:: r deg12%>% arrange(desc(avg_log2FC)) .. raw:: html
A data.frame: 115 × 5
p_valavg_log2FCpct.1pct.2p_val_adj
<dbl><dbl><dbl><dbl><dbl>
GZMH 0.000000e+002.33176120.8920.368 0.000000e+00
CD3D 0.000000e+001.98725580.9640.407 0.000000e+00
SCGB3A1 0.000000e+001.70287280.8280.307 0.000000e+00
TRGC25.580196e-2661.62345420.7000.3041.116039e-262
IFITM1 0.000000e+001.62089030.8430.318 0.000000e+00
TRAC 0.000000e+001.57333750.9430.461 0.000000e+00
TNF1.575880e-1581.55377260.5370.2243.151760e-155
CD3G2.002996e-3011.46699200.7140.2544.005991e-298
NKG77.615188e-3051.45838270.9900.5681.523038e-301
CCL53.413545e-2971.41281910.9720.4936.827090e-294
IL32 0.000000e+001.36565490.9680.544 0.000000e+00
SCGB1A1 0.000000e+001.34413760.8120.335 0.000000e+00
CD3E3.127342e-2761.25443170.8490.3996.254685e-273
GIMAP73.283782e-2531.25184230.8350.4346.567565e-250
GZMA4.304799e-2861.24140300.9460.5118.609598e-283
FGFBP21.511492e-1471.17898370.6480.3383.022983e-144
TRBC18.220764e-1851.13837990.8010.4291.644153e-181
GZMK 1.388654e-411.04807180.3730.242 2.777308e-38
CD8A 1.875675e-831.00576760.4640.258 3.751349e-80
CD21.581810e-2180.99743080.8210.3823.163619e-215
GZMM8.816690e-1620.98807190.7230.3971.763338e-158
CORO1A1.566353e-2290.97669450.9680.7353.132705e-226
MGP2.381943e-1530.95310540.6650.3854.763887e-150
ACKR1 2.414332e-780.94860060.3570.185 4.828664e-75
TRBC22.861630e-1130.94427780.7170.4365.723259e-110
CCL21 1.658734e-540.91739240.3580.222 3.317469e-51
PRF13.529078e-2270.89866980.8880.4657.058156e-224
C12orf752.574815e-1180.88996270.6280.3575.149629e-115
FCRL68.443549e-1300.87870690.4500.1771.688710e-126
S1PR57.000118e-1040.87086950.4910.2421.400024e-100
GZMB3.990067e-1550.38383380.8490.4687.980133e-152
NCR3 1.448325e-160.37654780.3710.290 2.896650e-13
RAB37 1.611220e-080.37534580.1940.178 3.222440e-05
CXCR3 3.049344e-140.37500410.2090.179 6.098688e-11
SYNE1 1.760211e-080.37300220.2150.210 3.520422e-05
RIPOR2 2.703798e-140.36610110.3520.304 5.407596e-11
TUBA4A 1.442729e-270.35856170.5080.407 2.885458e-24
ZNF683 1.843016e-010.35540560.1500.157 1.000000e+00
PTPN7 8.481600e-180.34794540.4500.383 1.696320e-14
C1orf21 2.250568e-110.34679130.2360.216 4.501136e-08
CCN1 2.585146e-100.33618220.1790.170 5.170293e-07
F2R 3.401221e-080.33335280.1980.160 6.802441e-05
B2M 8.769744e-880.32396781.0000.992 1.753949e-84
PPP2R2B 4.637321e-020.31843410.1560.152 1.000000e+00
PYHIN1 8.634472e-160.30388160.3810.302 1.726894e-12
GNG2 7.410162e-320.30182190.5140.386 1.482032e-28
DCN 6.905787e-090.28761150.2750.260 1.381157e-05
ZNF600 6.203896e-040.28512270.1730.195 1.000000e+00
SFTPB 3.032331e-240.28443820.4340.345 6.064663e-21
IFITM3 5.037570e-670.28280940.6920.422 1.007514e-63
PTPRC 7.126091e-540.28262170.8140.623 1.425218e-50
CD300A 4.182796e-060.27943540.3570.356 8.365592e-03
LPCAT1 8.864149e-210.27903470.3000.242 1.772830e-17
ADIRF 2.973978e-130.27558990.1850.164 5.947956e-10
HBB 4.200590e-720.27356060.4420.275 8.401180e-69
ID1 2.701749e-090.27239890.2090.201 5.403498e-06
GBP5 2.446865e-120.25858510.2150.197 4.893729e-09
MLLT6 1.151223e-010.25726200.1850.229 1.000000e+00
H2BC8 5.723035e-100.25676490.1040.218 1.144607e-06
TM4SF1 4.001418e-170.25189250.1550.133 8.002836e-14
.. code:: r Idents(heca.integrated)<-'integrated_snn_res.0.5' deg15 = FindMarkers(heca.integrated, only.pos = T, ident.1=15) .. code:: r deg15 .. raw:: html
A data.frame: 152 × 5
p_valavg_log2FCpct.1pct.2p_val_adj
<dbl><dbl><dbl><dbl><dbl>
GNLY 0.000000e+002.06967620.9950.524 0.000000e+00
PRF1 0.000000e+002.24716470.9860.466 0.000000e+00
CD247 0.000000e+001.77674130.9310.399 0.000000e+00
IFITM1 0.000000e+002.06924610.8740.320 0.000000e+00
NKG71.469025e-3021.86971030.9970.5702.938049e-299
KLRD11.069487e-2991.63948700.9670.4382.138975e-296
CTSW1.332831e-2991.72165660.9690.4922.665663e-296
SCGB3A11.197749e-2981.69345470.8160.3102.395498e-295
KLRF12.534747e-2941.56272280.8290.2945.069494e-291
GZMB1.259607e-2871.69065660.9760.4682.519214e-284
GZMA1.498221e-2821.70293050.9720.5132.996441e-279
SPON21.877297e-2811.79171680.8740.3863.754595e-278
HOPX1.411750e-2721.64247760.9320.4542.823501e-269
MYOM21.742244e-2412.02887100.6760.2413.484489e-238
SCGB1A19.854206e-2381.44114650.7830.3381.970841e-234
FCGR3A1.444223e-2311.50080750.9210.4442.888446e-228
KLRB13.819865e-2261.28268100.9150.4317.639731e-223
FGFBP21.663208e-2241.62260700.7950.3373.326416e-221
TRDC1.901180e-2061.47418510.7370.2933.802360e-203
CD72.533214e-2051.29911350.9050.4885.066429e-202
IGHG32.823892e-1990.38448240.5960.2005.647783e-196
CST71.957965e-1931.17773710.9360.5163.915930e-190
NCR31.599390e-1841.39578470.6820.2863.198781e-181
GZMM4.910456e-1761.31474460.7820.3989.820912e-173
CCL51.652247e-1701.24589280.9340.4963.304493e-167
CCL34.604424e-1691.16877780.9580.5789.208848e-166
LGALS132.207733e-1641.12944790.8580.4924.415465e-161
IFITM21.189061e-1621.00951390.9630.7122.378122e-159
S1PR51.006570e-1601.34398290.6020.2422.013141e-157
CORO1A3.843575e-1570.99570980.9540.7367.687149e-154
H4C32.676584e-050.27565150.3830.3790.05353168
DCN6.476969e-050.30022190.2590.2600.12953938
RAB379.406866e-050.37845170.1800.1780.18813732
FBXO441.205780e-040.33849890.1480.1660.24115597
MLLT63.747354e-040.32819900.2180.2290.74947080
S100B4.016167e-040.78412120.2130.2120.80323349
FCRL36.314218e-040.29500550.1080.0841.00000000
RIPOR21.591798e-030.36402700.2930.3061.00000000
PLA2G2A3.044196e-030.61364640.2450.2521.00000000
PIF13.263715e-030.28866110.0640.1281.00000000
FAM43A4.691287e-030.32050020.1460.2301.00000000
NNMT4.722701e-030.47594930.2070.2181.00000000
ADAMTS15.144521e-030.40077610.1220.1411.00000000
MCTP21.010765e-020.31662270.1600.1581.00000000
CXCR11.058021e-020.32133120.1020.0841.00000000
RNF1251.140217e-020.26679880.2250.2481.00000000
KIR3DL21.431669e-020.31418920.1250.1111.00000000
CRTAM1.467915e-020.52944610.1420.2331.00000000
CEP782.026967e-020.39320910.1950.2171.00000000
TPM23.734433e-020.26358150.1300.1751.00000000
PTGDS4.187003e-020.69702240.1900.2221.00000000
SH2D2A6.854395e-020.36481990.2550.2691.00000000
TNFSF141.114615e-010.38690450.1950.2301.00000000
SLFN12L1.769912e-010.33254730.1300.1811.00000000
NCALD2.030238e-010.28201670.1270.1381.00000000
ARRDC32.532969e-010.25200300.2760.3211.00000000
NEIL12.697969e-010.44164210.1560.1861.00000000
DTHD13.087544e-010.40261170.1710.1821.00000000
TNFRSF94.500554e-010.34008360.1140.1511.00000000
PPP2R2B8.506222e-010.30383830.1370.1521.00000000
.. code:: r coi = Cells(subset(heca.integrated, integrated_snn_res.0.5=='4')) heca.integrated@meta.data[coi, 'ann']<-'CD8 T cell' coi = Cells(subset(heca.integrated, integrated_snn_res.0.5=='12')) heca.integrated@meta.data[coi, 'ann']<-'CD8 T cell' .. code:: r o(10,10) DimPlot(heca.integrated, group.by='ann',label=T,cols = heca.color.table) .. image:: output_39_0.png :width: 600px :height: 600px .. code:: r save(heca.integrated, file = 'heca.integrated.annotated.rda', compress = T, compression_level = 9)