From 79a3e5152dfa81670cafccb1dd0f9c7f387fedf9 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Tue, 7 Jan 2025 15:37:10 -0600 Subject: [PATCH 01/15] script to save coldata --- .../scripts/03-save-coldata.R | 64 +++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 analyses/cell-type-consensus/scripts/03-save-coldata.R diff --git a/analyses/cell-type-consensus/scripts/03-save-coldata.R b/analyses/cell-type-consensus/scripts/03-save-coldata.R new file mode 100644 index 000000000..7473f3e35 --- /dev/null +++ b/analyses/cell-type-consensus/scripts/03-save-coldata.R @@ -0,0 +1,64 @@ +#!/usr/bin/env Rscript + +# This script is used to grab the colData from a SCE object and save it as a TSV file + +project_root <- here::here() + +library(optparse) + +option_list <- list( + make_option( + opt_str = c("--sce_file"), + type = "character", + help = "Path to RDS file containing a processed SingleCellExperiment object from scpca-nf" + ), + make_option( + opt_str = c("--output_file"), + type = "character", + help = "Path to file where colData will be saved, must end in `.tsv`" + ) +) + +# Parse options +opt <- parse_args(OptionParser(option_list = option_list)) + +# Set up ----------------------------------------------------------------------- + +# make sure input files exist +stopifnot( + "sce file does not exist" = file.exists(opt$sce_file) +) + +# load SCE +suppressPackageStartupMessages({ + library(SingleCellExperiment) +}) + +# Extract colData -------------------------------------------------------------- + +# read in sce +sce <- readr::read_rds(opt$sce_file) + +# extract ids +library_id <- metadata(sce)$library_id +sample_id <- metadata(sce)$sample_id +project_id <- metadata(sce)$project_id + +# get df with ids, barcodes, and cell type assignments +celltype_df <- colData(sce) |> + as.data.frame() |> + dplyr::mutate( + project_id = project_id, + sample_id = sample_id, + library_id = library_id + ) |> + dplyr::select( + ends_with("id"), + "barcodes", + contains("celltype") # get both singler and cellassign with ontology + ) + +# save tsv +readr::write_tsv(celltype_df, opt$output_file) + + From 84094b5bbd27bac5be3984201666a506e173531a Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Tue, 7 Jan 2025 14:51:46 -0600 Subject: [PATCH 02/15] keep original panglao name when creating reference --- .../consensus-cell-type-reference.tsv | 613 +++++++++--------- .../scripts/02-prepare-consensus-reference.R | 6 +- 2 files changed, 315 insertions(+), 304 deletions(-) diff --git a/analyses/cell-type-consensus/references/consensus-cell-type-reference.tsv b/analyses/cell-type-consensus/references/consensus-cell-type-reference.tsv index 18003c3d8..da7dcdc61 100644 --- a/analyses/cell-type-consensus/references/consensus-cell-type-reference.tsv +++ b/analyses/cell-type-consensus/references/consensus-cell-type-reference.tsv @@ -1,302 +1,311 @@ -panglao_ontology panglao_annotation blueprint_ontology blueprint_annotation_main blueprint_annotation_fine consensus_ontology consensus_annotation -CL:0000583 alveolar macrophage CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000767 basophil CL:0000775 Neutrophils Neutrophils CL:0000094 granulocyte -CL:0000771 eosinophil CL:0000775 Neutrophils Neutrophils CL:0000094 granulocyte -CL:0000235 macrophage CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000097 mast cell CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000576 monocyte CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000775 neutrophil CL:0000775 Neutrophils Neutrophils CL:0000775 neutrophil -CL:0000092 osteoclast CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000091 Kupffer cell CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000453 Langerhans cell CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000129 microglial cell CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000889 myeloid suppressor cell CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000874 splenic red pulp macrophage CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte -CL:0000767 basophil CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte -CL:0000451 dendritic cell CL:0000576 Monocytes Monocytes CL:0000113 mononuclear phagocyte -CL:0000771 eosinophil CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte -CL:0000097 mast cell CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte -CL:0000576 monocyte CL:0000576 Monocytes Monocytes CL:0000576 monocyte -CL:0000775 neutrophil CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte -CL:0000784 plasmacytoid dendritic cell CL:0000576 Monocytes Monocytes CL:0000113 mononuclear phagocyte -CL:0000889 myeloid suppressor cell CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte -CL:0000037 hematopoietic stem cell CL:0000050 HSC MEP CL:0008001 hematopoietic precursor cell -CL:0000038 erythroid progenitor cell CL:0000050 HSC MEP CL:0008001 hematopoietic precursor cell -CL:0000084 T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000624 CD4-positive, alpha-beta T cell -CL:0000893 thymocyte CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell -CL:0000815 regulatory T cell CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell -CL:0000084 T cell CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000893 thymocyte CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000898 naive T cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell -CL:0000815 regulatory T cell CL:0000815 CD4+ T-cells Tregs CL:0000815 regulatory T cell -CL:0000084 T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000624 CD4-positive, alpha-beta T cell -CL:0000893 thymocyte CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000813 memory T cell -CL:0000815 regulatory T cell CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell -CL:0000084 T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0000624 CD4-positive, alpha-beta T cell -CL:0000893 thymocyte CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0000813 memory T cell -CL:0000815 regulatory T cell CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell -CL:0000084 T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000791 mature alpha-beta T cell -CL:0000893 thymocyte CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000813 memory T cell -CL:0000815 regulatory T cell CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell -CL:0000084 T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0000791 mature alpha-beta T cell -CL:0000893 thymocyte CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0000813 memory T cell -CL:0000815 regulatory T cell CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell -CL:0000623 natural killer cell CL:0000623 NK cells NK cells CL:0000623 natural killer cell -CL:0001069 group 2 innate lymphoid cell CL:0000623 NK cells NK cells CL:0001065 innate lymphoid cell -CL:0000236 B cell CL:0000788 B-cells naive B-cells CL:0000236 B cell -CL:0000786 plasma cell CL:0000788 B-cells naive B-cells CL:0000945 lymphocyte of B lineage -CL:0000787 memory B cell CL:0000788 B-cells naive B-cells CL:0000785 mature B cell -CL:0000788 naive B cell CL:0000788 B-cells naive B-cells CL:0000788 naive B cell -CL:0000236 B cell CL:0000787 B-cells Memory B-cells CL:0000236 B cell -CL:0000786 plasma cell CL:0000787 B-cells Memory B-cells CL:0000945 lymphocyte of B lineage -CL:0000787 memory B cell CL:0000787 B-cells Memory B-cells CL:0000787 memory B cell -CL:0000788 naive B cell CL:0000787 B-cells Memory B-cells CL:0000785 mature B cell -CL:0000236 B cell CL:0000972 B-cells Class-switched memory B-cells CL:0000236 B cell -CL:0000786 plasma cell CL:0000972 B-cells Class-switched memory B-cells CL:0000945 lymphocyte of B lineage -CL:0000787 memory B cell CL:0000972 B-cells Class-switched memory B-cells CL:0000787 memory B cell -CL:0000788 naive B cell CL:0000972 B-cells Class-switched memory B-cells CL:0000785 mature B cell -CL:0000646 basal cell CL:0000037 HSC HSC CL:0000723 somatic stem cell -CL:0002322 embryonic stem cell CL:0000037 HSC HSC CL:0000034 stem cell -CL:0000352 epiblast cell CL:0000037 HSC HSC CL:0000723 somatic stem cell -CL:0000037 hematopoietic stem cell CL:0000037 HSC HSC CL:0000037 hematopoietic stem cell -CL:0005026 hepatoblast CL:0000037 HSC HSC CL:0000034 stem cell -CL:0002248 pluripotent stem cell CL:0000037 HSC HSC CL:0000723 somatic stem cell -CL:0002672 retinal progenitor cell CL:0000037 HSC HSC CL:0000034 stem cell -CL:0002664 cardioblast CL:0000037 HSC HSC CL:0000034 stem cell -CL:0002250 intestinal crypt stem cell CL:0000037 HSC HSC CL:0000034 stem cell -CL:0000038 erythroid progenitor cell CL:0000037 HSC HSC CL:0008001 hematopoietic precursor cell -CL:0000324 metanephric mesenchyme stem cell CL:0000037 HSC HSC CL:0000034 stem cell -CL:0000037 hematopoietic stem cell CL:0000837 HSC MPP CL:0008001 hematopoietic precursor cell -CL:0000038 erythroid progenitor cell CL:0000837 HSC MPP CL:0008001 hematopoietic precursor cell -CL:0000037 hematopoietic stem cell CL:0000051 HSC CLP CL:0008001 hematopoietic precursor cell -CL:0000038 erythroid progenitor cell CL:0000051 HSC CLP CL:0008001 hematopoietic precursor cell -CL:0000037 hematopoietic stem cell CL:0000557 HSC GMP CL:0008001 hematopoietic precursor cell -CL:0000038 erythroid progenitor cell CL:0000557 HSC GMP CL:0008001 hematopoietic precursor cell -CL:0000583 alveolar macrophage CL:0000235 Macrophages Macrophages CL:0000235 macrophage -CL:0000767 basophil CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte -CL:0000771 eosinophil CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte -CL:0000235 macrophage CL:0000235 Macrophages Macrophages CL:0000235 macrophage -CL:0000097 mast cell CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte -CL:0000775 neutrophil CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte -CL:0000091 Kupffer cell CL:0000235 Macrophages Macrophages CL:0000235 macrophage -CL:0000129 microglial cell CL:0000235 Macrophages Macrophages CL:0000235 macrophage -CL:0000889 myeloid suppressor cell CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte -CL:0000874 splenic red pulp macrophage CL:0000235 Macrophages Macrophages CL:0000235 macrophage -CL:0000084 T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell -CL:0002038 T follicular helper cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000791 mature alpha-beta T cell -CL:0000893 thymocyte CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell -CL:0000798 gamma-delta T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell -CL:0000814 mature NK T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000791 mature alpha-beta T cell -CL:0000898 naive T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell -CL:0000910 cytotoxic T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell -CL:0000912 helper T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell -CL:0000813 memory T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell -CL:0000815 regulatory T cell CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell -CL:0000765 erythroblast CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell -CL:0000558 reticulocyte CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell -CL:0000038 erythroid progenitor cell CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell -CL:0000556 megakaryocyte CL:0000556 HSC Megakaryocytes CL:0000556 megakaryocyte -CL:0000037 hematopoietic stem cell CL:0000049 HSC CMP CL:0008001 hematopoietic precursor cell -CL:0000038 erythroid progenitor cell CL:0000049 HSC CMP CL:0008001 hematopoietic precursor cell -CL:0000583 alveolar macrophage CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage -CL:0000767 basophil CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte -CL:0000771 eosinophil CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte -CL:0000235 macrophage CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage -CL:0000097 mast cell CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte -CL:0000775 neutrophil CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte -CL:0000091 Kupffer cell CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage -CL:0000129 microglial cell CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage -CL:0000889 myeloid suppressor cell CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte -CL:0000874 splenic red pulp macrophage CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage -CL:0000583 alveolar macrophage CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage -CL:0000767 basophil CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte -CL:0000771 eosinophil CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte -CL:0000235 macrophage CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage -CL:0000097 mast cell CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte -CL:0000775 neutrophil CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte -CL:0000091 Kupffer cell CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage -CL:0000129 microglial cell CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage -CL:0000889 myeloid suppressor cell CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte -CL:0000874 splenic red pulp macrophage CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage -CL:0000115 endothelial cell CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell -CL:0002544 aortic endothelial cell CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell -CL:2000044 brain microvascular endothelial cell CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell -CL:0000451 dendritic cell CL:0000451 DC DC CL:0000451 dendritic cell -CL:0000576 monocyte CL:0000451 DC DC CL:0000113 mononuclear phagocyte -CL:0000784 plasmacytoid dendritic cell CL:0000451 DC DC CL:0000451 dendritic cell -CL:0000453 Langerhans cell CL:0000451 DC DC CL:0000451 dendritic cell -CL:0000583 alveolar macrophage CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000767 basophil CL:0000771 Eosinophils Eosinophils CL:0000094 granulocyte -CL:0000771 eosinophil CL:0000771 Eosinophils Eosinophils CL:0000771 eosinophil -CL:0000235 macrophage CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000097 mast cell CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000576 monocyte CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000775 neutrophil CL:0000771 Eosinophils Eosinophils CL:0000094 granulocyte -CL:0000092 osteoclast CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000091 Kupffer cell CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000453 Langerhans cell CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000129 microglial cell CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000889 myeloid suppressor cell CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000874 splenic red pulp macrophage CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte -CL:0000236 B cell CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage -CL:0000786 plasma cell CL:0000786 B-cells Plasma cells CL:0000786 plasma cell -CL:0000787 memory B cell CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage -CL:0000788 naive B cell CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage -CL:0000138 chondrocyte CL:0000138 Chondrocytes Chondrocytes CL:0000138 chondrocyte -CL:2000002 decidual cell CL:0000138 Chondrocytes Chondrocytes CL:0000499 stromal cell -CL:0000632 hepatic stellate cell CL:0000138 Chondrocytes Chondrocytes CL:0000327 extracellular matrix secreting cell -CL:0000499 stromal cell CL:0000138 Chondrocytes Chondrocytes CL:0000499 stromal cell -CL:0000708 leptomeningeal cell CL:0000138 Chondrocytes Chondrocytes CL:0000327 extracellular matrix secreting cell -CL:0000057 fibroblast CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast -CL:0000632 hepatic stellate cell CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast -CL:0002410 pancreatic stellate cell CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast -CL:0002334 preadipocyte CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast -CL:0000192 smooth muscle cell CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell -CL:0019019 tracheobronchial smooth muscle cell CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell -CL:0000746 cardiac muscle cell CL:0000192 Smooth muscle Smooth muscle CL:0000187 muscle cell -CL:0000359 vascular associated smooth muscle cell CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell -CL:0002068 Purkinje myocyte CL:0000192 Smooth muscle Smooth muscle CL:0000187 muscle cell -CL:0000622 acinar cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:1000488 cholangiocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000166 chromaffin cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000584 enterocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000164 enteroendocrine cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000065 ependymal cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000066 epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000160 goblet cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000501 granulosa cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000182 hepatocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0005006 ionocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000312 keratinocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000077 mesothelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000185 myoepithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000165 neuroendocrine cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002167 olfactory epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000510 paneth cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000162 parietal cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002481 peritubular myoid cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000652 pinealocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000653 podocyte CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000209 taste receptor cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000731 urothelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002368 respiratory epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002370 respiratory goblet cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000171 pancreatic A cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000169 type B pancreatic cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000706 choroid plexus epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000158 club cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002250 intestinal crypt stem cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000173 pancreatic D cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002305 epithelial cell of distal tubule CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002079 pancreatic ductal cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000504 enterochromaffin-like cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0005019 pancreatic epsilon cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002258 thyroid follicular cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002179 foveolar cell of stomach CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000696 PP cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000155 peptic cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002292 type I cell of carotid body CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0005010 renal intercalated cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:1000909 kidney loop of Henle epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002326 luminal epithelial cell of mammary gland CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002327 mammary gland epithelial cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000242 Merkel cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000682 M cell of gut CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002199 oxyphil cell of parathyroid gland CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000446 chief cell of parathyroid gland CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0005009 renal principal cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002306 epithelial cell of proximal tubule CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002062 pulmonary alveolar type 1 cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002063 pulmonary alveolar type 2 cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:1001596 salivary gland glandular cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002140 acinar cell of sebaceous gland CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000216 Sertoli cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002562 hair germinal matrix cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0002204 brush cell CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell -CL:0000148 melanocyte CL:0000148 Melanocytes Melanocytes CL:0000148 melanocyte -CL:0000594 skeletal muscle satellite cell CL:0000188 Skeletal muscle Skeletal muscle CL:0000188 cell of skeletal muscle -CL:0000166 chromaffin cell CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0000065 ependymal cell CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0000312 keratinocyte CL:0000312 Keratinocytes Keratinocytes CL:0000312 keratinocyte -CL:0000077 mesothelial cell CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell -CL:0000165 neuroendocrine cell CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0002167 olfactory epithelial cell CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0002481 peritubular myoid cell CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell -CL:0000652 pinealocyte CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0000706 choroid plexus epithelial cell CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0002292 type I cell of carotid body CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell -CL:0000242 Merkel cell CL:0000312 Keratinocytes Keratinocytes CL:0000312 keratinocyte -CL:0002062 pulmonary alveolar type 1 cell CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell -CL:0002063 pulmonary alveolar type 2 cell CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell -CL:0002140 acinar cell of sebaceous gland CL:0000312 Keratinocytes Keratinocytes CL:0000362 epidermal cell -CL:0000216 Sertoli cell CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell -CL:0002562 hair germinal matrix cell CL:0000312 Keratinocytes Keratinocytes CL:0000362 epidermal cell -CL:0000115 endothelial cell CL:2000008 Endothelial cells mv Endothelial cells CL:0000115 endothelial cell -CL:0002544 aortic endothelial cell CL:2000008 Endothelial cells mv Endothelial cells CL:0000071 blood vessel endothelial cell -CL:2000044 brain microvascular endothelial cell CL:2000008 Endothelial cells mv Endothelial cells CL:2000008 microvascular endothelial cell -CL:0000192 smooth muscle cell CL:0000187 Myocytes Myocytes CL:0000187 muscle cell -CL:0019019 tracheobronchial smooth muscle cell CL:0000187 Myocytes Myocytes CL:0000187 muscle cell -CL:0000746 cardiac muscle cell CL:0000187 Myocytes Myocytes CL:0000187 muscle cell -CL:0000359 vascular associated smooth muscle cell CL:0000187 Myocytes Myocytes CL:0000187 muscle cell -CL:0002068 Purkinje myocyte CL:0000187 Myocytes Myocytes CL:0000187 muscle cell -CL:0000136 adipocyte CL:0000136 Adipocytes Adipocytes CL:0000136 adipocyte -CL:0000650 mesangial cell CL:0000669 Pericytes Pericytes CL:0000669 pericyte -CL:0000669 pericyte CL:0000669 Pericytes Pericytes CL:0000669 pericyte -CL:0000127 astrocyte CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte -CL:0000065 ependymal cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:0000128 oligodendrocyte CL:0000127 Astrocytes Astrocytes CL:0000126 macroglial cell -CL:0002085 tanycyte CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte -CL:0000644 Bergmann glial cell CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte -CL:0000706 choroid plexus epithelial cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:4040002 enteroglial cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:4042021 neuronal-restricted precursor CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell -CL:0000242 Merkel cell CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell -CL:0000129 microglial cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:0000636 Mueller cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:0002453 oligodendrocyte precursor cell CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell -CL:0002573 Schwann cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:0000681 radial glial cell CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell -CL:0000516 perineural satellite cell CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell -CL:0000650 mesangial cell CL:0000650 Mesangial cells Mesangial cells CL:0000650 mesangial cell -CL:0000669 pericyte CL:0000650 Mesangial cells Mesangial cells CL:0000669 pericyte +panglao_ontology panglao_annotation original_panglao_name blueprint_ontology blueprint_annotation_main blueprint_annotation_fine consensus_ontology consensus_annotation +CL:0000583 alveolar macrophage Alveolar macrophages CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000767 basophil Basophils CL:0000775 Neutrophils Neutrophils CL:0000094 granulocyte +CL:0000771 eosinophil Eosinophils CL:0000775 Neutrophils Neutrophils CL:0000094 granulocyte +CL:0000235 macrophage Macrophages CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000097 mast cell Mast cells CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000576 monocyte Monocytes CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000576 monocyte Osteoclast precursor cells CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000775 neutrophil Neutrophils CL:0000775 Neutrophils Neutrophils CL:0000775 neutrophil +CL:0000092 osteoclast Osteoclasts CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000091 Kupffer cell Kupffer cells CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000453 Langerhans cell Langerhans cells CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000129 microglial cell Microglia CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000874 splenic red pulp macrophage Red pulp macrophages CL:0000775 Neutrophils Neutrophils CL:0000766 myeloid leukocyte +CL:0000767 basophil Basophils CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte +CL:0000451 dendritic cell Dendritic cells CL:0000576 Monocytes Monocytes CL:0000113 mononuclear phagocyte +CL:0000771 eosinophil Eosinophils CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte +CL:0000097 mast cell Mast cells CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte +CL:0000576 monocyte Monocytes CL:0000576 Monocytes Monocytes CL:0000576 monocyte +CL:0000576 monocyte Osteoclast precursor cells CL:0000576 Monocytes Monocytes CL:0000576 monocyte +CL:0000775 neutrophil Neutrophils CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte +CL:0000784 plasmacytoid dendritic cell Plasmacytoid dendritic cells CL:0000576 Monocytes Monocytes CL:0000113 mononuclear phagocyte +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000576 Monocytes Monocytes CL:0000766 myeloid leukocyte +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000050 HSC MEP CL:0008001 hematopoietic precursor cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000050 HSC MEP CL:0008001 hematopoietic precursor cell +CL:0000084 T cell T cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000624 CD4-positive, alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000624 CD4+ T-cells CD4+ T-cells CL:0002419 mature T cell +CL:0000084 T cell T cells CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000893 thymocyte Thymocytes CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000815 CD4+ T-cells Tregs CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000898 naive T cell T cells naive CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000815 CD4+ T-cells Tregs CL:0002419 mature T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000815 CD4+ T-cells Tregs CL:0000815 regulatory T cell +CL:0000084 T cell T cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000624 CD4-positive, alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0000813 memory T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000904 CD4+ T-cells CD4+ Tcm CL:0002419 mature T cell +CL:0000084 T cell T cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0000624 CD4-positive, alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0000813 memory T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000905 CD4+ T-cells CD4+ Tem CL:0002419 mature T cell +CL:0000084 T cell T cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000791 mature alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0000813 memory T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000907 CD8+ T-cells CD8+ Tcm CL:0002419 mature T cell +CL:0000084 T cell T cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0000791 mature alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0000813 memory T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000913 CD8+ T-cells CD8+ Tem CL:0002419 mature T cell +CL:0000623 natural killer cell NK cells CL:0000623 NK cells NK cells CL:0000623 natural killer cell +CL:0001069 group 2 innate lymphoid cell Nuocytes CL:0000623 NK cells NK cells CL:0001065 innate lymphoid cell +CL:0000236 B cell B cells CL:0000788 B-cells naive B-cells CL:0000236 B cell +CL:0000786 plasma cell Plasma cells CL:0000788 B-cells naive B-cells CL:0000945 lymphocyte of B lineage +CL:0000787 memory B cell B cells memory CL:0000788 B-cells naive B-cells CL:0000785 mature B cell +CL:0000788 naive B cell B cells naive CL:0000788 B-cells naive B-cells CL:0000788 naive B cell +CL:0000236 B cell B cells CL:0000787 B-cells Memory B-cells CL:0000236 B cell +CL:0000786 plasma cell Plasma cells CL:0000787 B-cells Memory B-cells CL:0000945 lymphocyte of B lineage +CL:0000787 memory B cell B cells memory CL:0000787 B-cells Memory B-cells CL:0000787 memory B cell +CL:0000788 naive B cell B cells naive CL:0000787 B-cells Memory B-cells CL:0000785 mature B cell +CL:0000236 B cell B cells CL:0000972 B-cells Class-switched memory B-cells CL:0000236 B cell +CL:0000786 plasma cell Plasma cells CL:0000972 B-cells Class-switched memory B-cells CL:0000945 lymphocyte of B lineage +CL:0000787 memory B cell B cells memory CL:0000972 B-cells Class-switched memory B-cells CL:0000787 memory B cell +CL:0000788 naive B cell B cells naive CL:0000972 B-cells Class-switched memory B-cells CL:0000785 mature B cell +CL:0000646 basal cell Basal cells CL:0000037 HSC HSC CL:0000723 somatic stem cell +CL:0002322 embryonic stem cell Embryonic stem cells CL:0000037 HSC HSC CL:0000034 stem cell +CL:0000352 epiblast cell Epiblast cells CL:0000037 HSC HSC CL:0000723 somatic stem cell +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000037 HSC HSC CL:0000037 hematopoietic stem cell +CL:0005026 hepatoblast Hepatoblasts CL:0000037 HSC HSC CL:0000034 stem cell +CL:0002248 pluripotent stem cell Pluripotent stem cells CL:0000037 HSC HSC CL:0000723 somatic stem cell +CL:0002672 retinal progenitor cell Retinal progenitor cells CL:0000037 HSC HSC CL:0000034 stem cell +CL:0002664 cardioblast Cardiac stem and precursor cells CL:0000037 HSC HSC CL:0000034 stem cell +CL:0002250 intestinal crypt stem cell Crypt cells CL:0000037 HSC HSC CL:0000034 stem cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000037 HSC HSC CL:0008001 hematopoietic precursor cell +CL:0000324 metanephric mesenchyme stem cell Kidney progenitor cells CL:0000037 HSC HSC CL:0000034 stem cell +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000837 HSC MPP CL:0008001 hematopoietic precursor cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000837 HSC MPP CL:0008001 hematopoietic precursor cell +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000051 HSC CLP CL:0008001 hematopoietic precursor cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000051 HSC CLP CL:0008001 hematopoietic precursor cell +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000557 HSC GMP CL:0008001 hematopoietic precursor cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000557 HSC GMP CL:0008001 hematopoietic precursor cell +CL:0000583 alveolar macrophage Alveolar macrophages CL:0000235 Macrophages Macrophages CL:0000235 macrophage +CL:0000767 basophil Basophils CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte +CL:0000771 eosinophil Eosinophils CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte +CL:0000235 macrophage Macrophages CL:0000235 Macrophages Macrophages CL:0000235 macrophage +CL:0000097 mast cell Mast cells CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte +CL:0000775 neutrophil Neutrophils CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte +CL:0000091 Kupffer cell Kupffer cells CL:0000235 Macrophages Macrophages CL:0000235 macrophage +CL:0000129 microglial cell Microglia CL:0000235 Macrophages Macrophages CL:0000235 macrophage +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000235 Macrophages Macrophages CL:0000766 myeloid leukocyte +CL:0000874 splenic red pulp macrophage Red pulp macrophages CL:0000235 Macrophages Macrophages CL:0000235 macrophage +CL:0000084 T cell T cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell +CL:0002038 T follicular helper cell T follicular helper cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000791 mature alpha-beta T cell +CL:0000893 thymocyte Thymocytes CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell +CL:0000798 gamma-delta T cell Gamma delta T cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000084 T cell +CL:0000814 mature NK T cell Natural killer T cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0000791 mature alpha-beta T cell +CL:0000898 naive T cell T cells naive CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell +CL:0000910 cytotoxic T cell T cytotoxic cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell +CL:0000912 helper T cell T helper cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell +CL:0000813 memory T cell T memory cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell +CL:0000815 regulatory T cell T regulatory cells CL:0000625 CD8+ T-cells CD8+ T-cells CL:0002419 mature T cell +CL:0000765 erythroblast Erythroblasts CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell +CL:0000558 reticulocyte Reticulocytes CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000232 Erythrocytes Erythrocytes CL:0000764 erythroid lineage cell +CL:0000556 megakaryocyte Megakaryocytes CL:0000556 HSC Megakaryocytes CL:0000556 megakaryocyte +CL:0000037 hematopoietic stem cell Hematopoietic stem cells CL:0000049 HSC CMP CL:0008001 hematopoietic precursor cell +CL:0000038 erythroid progenitor cell Erythroid-like and erythroid precursor cells CL:0000049 HSC CMP CL:0008001 hematopoietic precursor cell +CL:0000583 alveolar macrophage Alveolar macrophages CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage +CL:0000767 basophil Basophils CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte +CL:0000771 eosinophil Eosinophils CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte +CL:0000235 macrophage Macrophages CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage +CL:0000097 mast cell Mast cells CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte +CL:0000775 neutrophil Neutrophils CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte +CL:0000091 Kupffer cell Kupffer cells CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage +CL:0000129 microglial cell Microglia CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000863 Macrophages Macrophages M1 CL:0000766 myeloid leukocyte +CL:0000874 splenic red pulp macrophage Red pulp macrophages CL:0000863 Macrophages Macrophages M1 CL:0000235 macrophage +CL:0000583 alveolar macrophage Alveolar macrophages CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage +CL:0000767 basophil Basophils CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte +CL:0000771 eosinophil Eosinophils CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte +CL:0000235 macrophage Macrophages CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage +CL:0000097 mast cell Mast cells CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte +CL:0000775 neutrophil Neutrophils CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte +CL:0000091 Kupffer cell Kupffer cells CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage +CL:0000129 microglial cell Microglia CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000890 Macrophages Macrophages M2 CL:0000766 myeloid leukocyte +CL:0000874 splenic red pulp macrophage Red pulp macrophages CL:0000890 Macrophages Macrophages M2 CL:0000235 macrophage +CL:0000115 endothelial cell Endothelial cells CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell +CL:0002544 aortic endothelial cell Endothelial cells (aorta) CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell +CL:2000044 brain microvascular endothelial cell Endothelial cells (blood brain barrier) CL:0000115 Endothelial cells Endothelial cells CL:0000115 endothelial cell +CL:0000451 dendritic cell Dendritic cells CL:0000451 DC DC CL:0000451 dendritic cell +CL:0000576 monocyte Monocytes CL:0000451 DC DC CL:0000113 mononuclear phagocyte +CL:0000576 monocyte Osteoclast precursor cells CL:0000451 DC DC CL:0000113 mononuclear phagocyte +CL:0000784 plasmacytoid dendritic cell Plasmacytoid dendritic cells CL:0000451 DC DC CL:0000451 dendritic cell +CL:0000453 Langerhans cell Langerhans cells CL:0000451 DC DC CL:0000451 dendritic cell +CL:0000583 alveolar macrophage Alveolar macrophages CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000767 basophil Basophils CL:0000771 Eosinophils Eosinophils CL:0000094 granulocyte +CL:0000771 eosinophil Eosinophils CL:0000771 Eosinophils Eosinophils CL:0000771 eosinophil +CL:0000235 macrophage Macrophages CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000097 mast cell Mast cells CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000576 monocyte Monocytes CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000576 monocyte Osteoclast precursor cells CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000775 neutrophil Neutrophils CL:0000771 Eosinophils Eosinophils CL:0000094 granulocyte +CL:0000092 osteoclast Osteoclasts CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000091 Kupffer cell Kupffer cells CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000453 Langerhans cell Langerhans cells CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000129 microglial cell Microglia CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000889 myeloid suppressor cell Myeloid-derived suppressor cells CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000874 splenic red pulp macrophage Red pulp macrophages CL:0000771 Eosinophils Eosinophils CL:0000766 myeloid leukocyte +CL:0000236 B cell B cells CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage +CL:0000786 plasma cell Plasma cells CL:0000786 B-cells Plasma cells CL:0000786 plasma cell +CL:0000787 memory B cell B cells memory CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage +CL:0000788 naive B cell B cells naive CL:0000786 B-cells Plasma cells CL:0000945 lymphocyte of B lineage +CL:0000138 chondrocyte Chondrocytes CL:0000138 Chondrocytes Chondrocytes CL:0000138 chondrocyte +CL:2000002 decidual cell Decidual cells CL:0000138 Chondrocytes Chondrocytes CL:0000499 stromal cell +CL:0000632 hepatic stellate cell Hepatic stellate cells CL:0000138 Chondrocytes Chondrocytes CL:0000327 extracellular matrix secreting cell +CL:0000499 stromal cell Stromal cells CL:0000138 Chondrocytes Chondrocytes CL:0000499 stromal cell +CL:0000708 leptomeningeal cell Meningeal cells CL:0000138 Chondrocytes Chondrocytes CL:0000327 extracellular matrix secreting cell +CL:0000057 fibroblast Fibroblasts CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast +CL:0000632 hepatic stellate cell Hepatic stellate cells CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast +CL:0002410 pancreatic stellate cell Pancreatic stellate cells CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast +CL:0002334 preadipocyte Adipocyte progenitor cells CL:0000057 Fibroblasts Fibroblasts CL:0000057 fibroblast +CL:0000192 smooth muscle cell Smooth muscle cells CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell +CL:0019019 tracheobronchial smooth muscle cell Airway smooth muscle cells CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell +CL:0000746 cardiac muscle cell Cardiomyocytes CL:0000192 Smooth muscle Smooth muscle CL:0000187 muscle cell +CL:0000746 cardiac muscle cell Myocytes CL:0000192 Smooth muscle Smooth muscle CL:0000187 muscle cell +CL:0000359 vascular associated smooth muscle cell Pulmonary vascular smooth muscle cells CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell +CL:0000359 vascular associated smooth muscle cell Vascular smooth muscle cells CL:0000192 Smooth muscle Smooth muscle CL:0000192 smooth muscle cell +CL:0002068 Purkinje myocyte Purkinje fiber cells CL:0000192 Smooth muscle Smooth muscle CL:0000187 muscle cell +CL:0000622 acinar cell Acinar cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:1000488 cholangiocyte Cholangiocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000166 chromaffin cell Chromaffin cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000584 enterocyte Enterocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000164 enteroendocrine cell Enteroendocrine cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000065 ependymal cell Ependymal cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000066 epithelial cell Epithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000160 goblet cell Goblet cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000501 granulosa cell Granulosa cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000182 hepatocyte Hepatocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0005006 ionocyte Ionocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000312 keratinocyte Keratinocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000077 mesothelial cell Mesothelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000185 myoepithelial cell Myoepithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000165 neuroendocrine cell Neuroendocrine cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002167 olfactory epithelial cell Olfactory epithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000510 paneth cell Paneth cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000162 parietal cell Parietal cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002481 peritubular myoid cell Peritubular myoid cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000652 pinealocyte Pinealocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000653 podocyte Podocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000209 taste receptor cell Taste receptor cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000731 urothelial cell Urothelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002368 respiratory epithelial cell Airway epithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002370 respiratory goblet cell Airway goblet cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000171 pancreatic A cell Alpha cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000169 type B pancreatic cell Beta cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000706 choroid plexus epithelial cell Choroid plexus cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000158 club cell Clara cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002250 intestinal crypt stem cell Crypt cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000173 pancreatic D cell Delta cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002305 epithelial cell of distal tubule Distal tubule cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002079 pancreatic ductal cell Ductal cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000504 enterochromaffin-like cell Enterochromaffin cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0005019 pancreatic epsilon cell Epsilon cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002258 thyroid follicular cell Follicular cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002179 foveolar cell of stomach Foveolar cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000696 PP cell Gamma (PP) cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000155 peptic cell Gastric chief cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002292 type I cell of carotid body Glomus cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0005010 renal intercalated cell Intercalated cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:1000909 kidney loop of Henle epithelial cell Loop of Henle cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002326 luminal epithelial cell of mammary gland Luminal epithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002327 mammary gland epithelial cell Mammary epithelial cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000242 Merkel cell Merkel cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000682 M cell of gut Microfold cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002199 oxyphil cell of parathyroid gland Oxyphil cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000446 chief cell of parathyroid gland Parathyroid chief cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0005009 renal principal cell Principal cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002306 epithelial cell of proximal tubule Proximal tubule cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002062 pulmonary alveolar type 1 cell Pulmonary alveolar type I cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002063 pulmonary alveolar type 2 cell Pulmonary alveolar type II cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:1001596 salivary gland glandular cell Salivary mucous cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002140 acinar cell of sebaceous gland Sebocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000216 Sertoli cell Sertoli cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002562 hair germinal matrix cell Trichocytes CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0002204 brush cell Tuft cells CL:0000066 Epithelial cells Epithelial cells CL:0000066 epithelial cell +CL:0000148 melanocyte Melanocytes CL:0000148 Melanocytes Melanocytes CL:0000148 melanocyte +CL:0000594 skeletal muscle satellite cell Satellite cells CL:0000188 Skeletal muscle Skeletal muscle CL:0000188 cell of skeletal muscle +CL:0000166 chromaffin cell Chromaffin cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0000065 ependymal cell Ependymal cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0000312 keratinocyte Keratinocytes CL:0000312 Keratinocytes Keratinocytes CL:0000312 keratinocyte +CL:0000077 mesothelial cell Mesothelial cells CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell +CL:0000165 neuroendocrine cell Neuroendocrine cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0002167 olfactory epithelial cell Olfactory epithelial cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0002481 peritubular myoid cell Peritubular myoid cells CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell +CL:0000652 pinealocyte Pinealocytes CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0000706 choroid plexus epithelial cell Choroid plexus cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0002292 type I cell of carotid body Glomus cells CL:0000312 Keratinocytes Keratinocytes CL:0002077 ecto-epithelial cell +CL:0000242 Merkel cell Merkel cells CL:0000312 Keratinocytes Keratinocytes CL:0000312 keratinocyte +CL:0002062 pulmonary alveolar type 1 cell Pulmonary alveolar type I cells CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell +CL:0002063 pulmonary alveolar type 2 cell Pulmonary alveolar type II cells CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell +CL:0002140 acinar cell of sebaceous gland Sebocytes CL:0000312 Keratinocytes Keratinocytes CL:0000362 epidermal cell +CL:0000216 Sertoli cell Sertoli cells CL:0000312 Keratinocytes Keratinocytes CL:0000076 squamous epithelial cell +CL:0002562 hair germinal matrix cell Trichocytes CL:0000312 Keratinocytes Keratinocytes CL:0000362 epidermal cell +CL:0000115 endothelial cell Endothelial cells CL:2000008 Endothelial cells mv Endothelial cells CL:0000115 endothelial cell +CL:0002544 aortic endothelial cell Endothelial cells (aorta) CL:2000008 Endothelial cells mv Endothelial cells CL:0000071 blood vessel endothelial cell +CL:2000044 brain microvascular endothelial cell Endothelial cells (blood brain barrier) CL:2000008 Endothelial cells mv Endothelial cells CL:2000008 microvascular endothelial cell +CL:0000192 smooth muscle cell Smooth muscle cells CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0019019 tracheobronchial smooth muscle cell Airway smooth muscle cells CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0000746 cardiac muscle cell Cardiomyocytes CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0000746 cardiac muscle cell Myocytes CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0000359 vascular associated smooth muscle cell Pulmonary vascular smooth muscle cells CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0000359 vascular associated smooth muscle cell Vascular smooth muscle cells CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0002068 Purkinje myocyte Purkinje fiber cells CL:0000187 Myocytes Myocytes CL:0000187 muscle cell +CL:0000136 adipocyte Adipocytes CL:0000136 Adipocytes Adipocytes CL:0000136 adipocyte +CL:0000650 mesangial cell Mesangial cells CL:0000669 Pericytes Pericytes CL:0000669 pericyte +CL:0000669 pericyte Pericytes CL:0000669 Pericytes Pericytes CL:0000669 pericyte +CL:0000127 astrocyte Astrocytes CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte +CL:0000065 ependymal cell Ependymal cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0000128 oligodendrocyte Oligodendrocytes CL:0000127 Astrocytes Astrocytes CL:0000126 macroglial cell +CL:0002085 tanycyte Tanycytes CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte +CL:0000644 Bergmann glial cell Bergmann glia CL:0000127 Astrocytes Astrocytes CL:0000127 astrocyte +CL:0000706 choroid plexus epithelial cell Choroid plexus cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:4040002 enteroglial cell Enteric glia cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:4042021 neuronal-restricted precursor Immature neurons CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell +CL:0000242 Merkel cell Merkel cells CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell +CL:0000129 microglial cell Microglia CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0000636 Mueller cell Müller cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0002453 oligodendrocyte precursor cell Oligodendrocyte progenitor cells CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell +CL:0002573 Schwann cell Peri-islet Schwann cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0002573 Schwann cell Schwann cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0000681 radial glial cell Radial glia cells CL:0000127 Astrocytes Astrocytes CL:0000125 glial cell +CL:0000516 perineural satellite cell Satellite glial cells CL:0000127 Astrocytes Astrocytes CL:0000095 neuron associated cell +CL:0000650 mesangial cell Mesangial cells CL:0000650 Mesangial cells Mesangial cells CL:0000650 mesangial cell +CL:0000669 pericyte Pericytes CL:0000650 Mesangial cells Mesangial cells CL:0000669 pericyte diff --git a/analyses/cell-type-consensus/scripts/02-prepare-consensus-reference.R b/analyses/cell-type-consensus/scripts/02-prepare-consensus-reference.R index 4171ed363..3915685a0 100644 --- a/analyses/cell-type-consensus/scripts/02-prepare-consensus-reference.R +++ b/analyses/cell-type-consensus/scripts/02-prepare-consensus-reference.R @@ -27,10 +27,11 @@ panglao_df <- readr::read_tsv(panglao_ref_file) |> # rename columns to have panglao in them for easy joining later dplyr::select( panglao_ontology = "ontology_id", - panglao_annotation = "human_readable_value" + panglao_annotation = "human_readable_value", + original_panglao_name = "panglao_cell_type" # keep original name since some map to the same ontology ID ) |> # remove any cell types that don't have ontologies - tidyr::drop_na() + tidyr::drop_na() # grab singler ref from celldex blueprint_ref <- celldex::BlueprintEncodeData() @@ -116,6 +117,7 @@ consensus_labels_df <- lca_df |> dplyr::select( panglao_ontology, panglao_annotation, + original_panglao_name, blueprint_ontology, blueprint_annotation_main, blueprint_annotation_fine, From 73d9498e3f3e4c85b69fd411f7b627a8c2aebf21 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 11:38:01 -0600 Subject: [PATCH 03/15] shell script to assign cell types for all scpca projects --- .../assign-consensus-celltypes.sh | 52 +++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 analyses/cell-type-consensus/assign-consensus-celltypes.sh diff --git a/analyses/cell-type-consensus/assign-consensus-celltypes.sh b/analyses/cell-type-consensus/assign-consensus-celltypes.sh new file mode 100644 index 000000000..dd6c7b643 --- /dev/null +++ b/analyses/cell-type-consensus/assign-consensus-celltypes.sh @@ -0,0 +1,52 @@ +#!/bin/bash + +# This script is used to create a single table with cell type assignments all cells from all ScPCA samples +# The existing cell type annotations from SingleR and CellAssign are saved to a TSV file for each sample +# Then all TSV files are combined into a single file and consensus cell types are assigned + +# Usage: ./evaluate-clusters.sh + +# to skip clustering and calculating metrics again: +# skip_metrics=1 ./evaluate-clusters.sh + +set -euo pipefail + +# navigate to where script lives +cd $(dirname "$0") +module_dir=$(pwd) + +data_dir="${module_dir}/../../data/current" +# path to save consensus results +scpca_consensus_assignments_file="${module_dir}/results/scpca-consensus-celltype-assignments.tsv" +# directory to store all individual tsv files +celltype_tsv_dir="${module_dir}/results/original-celltype-assignments" +mkdir -p ${celltype_tsv_dir} + +# define scripts and notebook directories +scripts_dir="${module_dir}/scripts" + +# define reference input files +panglao_ref_file="${module_dir}/references/panglao-cell-type-ontologies.tsv" +consensus_ref_file="${module_dir}/references/consensus-cell-type-reference.tsv" + +# run script to export tsv file on all processed objects +for sce_file in $data_dir/*/SCPCS*/*_processed.rds; do + + # define library ID + library_id=$(basename $sce_file | sed 's/_processed.rds$//') + + echo "Grabbing cell types for ${library_id}" + # get celltypes as tsv file + Rscript $scripts_dir/03-save-coldata.R \ + --sce_file $sce_file \ + --output_file ${celltype_tsv_dir}/${library_id}_celltype-assignments.tsv + +done + +echo "Combining TSVs and adding consensus labels" +# run script to combine all tsv files and assign consensus cell types +Rscript $scripts_dir/04-combine-celltype-tables.R \ + --celltype_tsv_dir $celltype_tsv_dir \ + --panglao_ref_file $panglao_ref_file \ + --consensus_ref_file $consensus_ref_file \ + --output_file $scpca_consensus_assignments_file From 2a2f514cda7f86b82f31611c6e06fcd9d8c1fede Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 11:38:13 -0600 Subject: [PATCH 04/15] account for cell line samples when saving tsv files --- .../scripts/03-save-coldata.R | 39 +++++++++++-------- 1 file changed, 23 insertions(+), 16 deletions(-) diff --git a/analyses/cell-type-consensus/scripts/03-save-coldata.R b/analyses/cell-type-consensus/scripts/03-save-coldata.R index 7473f3e35..dec64c46d 100644 --- a/analyses/cell-type-consensus/scripts/03-save-coldata.R +++ b/analyses/cell-type-consensus/scripts/03-save-coldata.R @@ -44,21 +44,28 @@ library_id <- metadata(sce)$library_id sample_id <- metadata(sce)$sample_id project_id <- metadata(sce)$project_id -# get df with ids, barcodes, and cell type assignments -celltype_df <- colData(sce) |> - as.data.frame() |> - dplyr::mutate( - project_id = project_id, - sample_id = sample_id, - library_id = library_id - ) |> - dplyr::select( - ends_with("id"), - "barcodes", - contains("celltype") # get both singler and cellassign with ontology - ) - -# save tsv -readr::write_tsv(celltype_df, opt$output_file) +# check if cell line since cell lines don't have any cell type assignments +is_cell_line <- metadata(sce)$sample_type == "cell line" +# only create and write table for non-cell line samples +if(!is_cell_line){ + + # get df with ids, barcodes, and cell type assignments + celltype_df <- colData(sce) |> + as.data.frame() |> + dplyr::mutate( + project_id = project_id, + sample_id = sample_id, + library_id = library_id + ) |> + dplyr::select( + ends_with("id"), + "barcodes", + contains("celltype") # get both singler and cellassign with ontology + ) + + # save tsv + readr::write_tsv(celltype_df, opt$output_file) + +} From 82632b79e94b1234e87074432a8a0745282e53b6 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 11:44:37 -0600 Subject: [PATCH 05/15] script to combine tsvs and add consensus --- .../scripts/04-combine-celltype-tables.R | 106 ++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R diff --git a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R new file mode 100644 index 000000000..78adffd75 --- /dev/null +++ b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R @@ -0,0 +1,106 @@ +#!/usr/bin/env Rscript + +# This script is used to combine all TSV files containing cell types into a single TSV file +# The output TSV file will include the following added columns: +# panglao_ontology: CL term assigned to panglao term +# panglao_annotation: human readable value associated with the CL term for panglao term +# blueprint_annotation_fine: Fine-grained annotation from blueprint associated with singler_celltype_ontology +# consensus_annotation: human readable name associated with the consensus label +# consensus_ontology: CL ontology term for the consensus cell type + +project_root <- here::here() + +library(optparse) + +option_list <- list( + make_option( + opt_str = c("--celltype_tsv_dir"), + type = "character", + help = "Path to directory containing TSV files with cell type annotations from single samples. + All TSV files in this directory will be combined into a single file." + ), + make_option( + opt_str = c("--panglao_ref_file"), + default = file.path(project_root, "references", "panglao-cell-type-ontologies.tsv"), + type = "character", + help = "Path to file with panglao assignments and associated cell ontology ids" + ), + make_option( + opt_str = c("--consensus_ref_file"), + default = file.path(project_root, "references", "consensus-cell-type-reference.tsv"), + type = "character", + help = "Path to file containing the reference for assigning consensus cell type labels" + ), + make_option( + opt_str = c("--output_file"), + type = "character", + help = "Path to file where combined TSV file will be saved, must end in `.tsv`" + ) +) + +# Parse options +opt <- parse_args(OptionParser(option_list = option_list)) + +# Prep ref files --------------------------------------------------------------- + +# make sure reference files exist +stopifnot( + "panglao reference file does not exist" = file.exists(opt$panglao_ref_file), + "cell type consensus reference file does not exist" = file.exists(opt$consensus_ref_file) +) + +# read in ref files +# change names for panglao ref to match what's in the consensus file +panglao_ref_df <- readr::read_tsv(opt$panglao_ref_file) |> + dplyr::rename( + panglao_ontology = ontology_id, + panglao_annotation = human_readable_value, + original_panglao_name = panglao_cell_type + ) + +consensus_ref_df <- readr::read_tsv(opt$consensus_ref_file) |> + # select columns to use for joining and consensus assigmments + dplyr::select( + panglao_ontology, + original_panglao_name, + blueprint_ontology, + consensus_annotation, + consensus_ontology + ) + +# grab singler ref from celldex +blueprint_ref <- celldex::BlueprintEncodeData() + +# get ontologies and human readable name into data frame for blueprint +# in scpca-nf we don't include the fine label so this lets us add it in +blueprint_df <- data.frame( + blueprint_ontology = blueprint_ref$label.ont, + blueprint_annotation_fine = blueprint_ref$label.fine +) |> + unique() |> + tidyr::drop_na() + +# get list of all TSV files +all_files <- list.files(path = opt$celltype_tsv_dir, + pattern = "*.tsv", + full.names = TRUE) + +# read in TSV files and combine into a single df +all_cells_df <- all_files |> + purrr::map(readr::read_tsv) |> + dplyr::bind_rows() |> + # add columns for panglao ontology and consensus + # first add panglao ontology + dplyr::left_join(panglao_ref_df, by = c("cellassign_celltype_annotation" = "original_panglao_name")) |> + # now add in all the blueprint columns + dplyr::left_join(blueprint_df, by = c("singler_celltype_ontology" = "blueprint_ontology")) |> + # then add consensus labels + dplyr::left_join(consensus_ref_df, + by = c("singler_celltype_ontology" = "blueprint_ontology", + "cellassign_celltype_annotation" = "original_panglao_name", + "panglao_ontology")) |> + # use unknown for NA annotation but keep ontology ID as NA + dplyr::mutate(consensus_annotation = dplyr::if_else(is.na(consensus_annotation), "Unknown", consensus_annotation)) + +# export file +readr::write_tsv(all_cells_df, opt$output_file) From f3b6f78c0d81d70bbc57b64fdf40fb933f94a380 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 11:47:01 -0600 Subject: [PATCH 06/15] update lock file --- analyses/cell-type-consensus/renv.lock | 39 ++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/analyses/cell-type-consensus/renv.lock b/analyses/cell-type-consensus/renv.lock index 0e6a57bb8..1912a8caa 100644 --- a/analyses/cell-type-consensus/renv.lock +++ b/analyses/cell-type-consensus/renv.lock @@ -549,6 +549,23 @@ ], "Hash": "20149fcead4dd6f9da3605f98b5220fc" }, + "SingleCellExperiment": { + "Package": "SingleCellExperiment", + "Version": "1.28.1", + "Source": "Bioconductor", + "Repository": "Bioconductor 3.20", + "Requirements": [ + "BiocGenerics", + "DelayedArray", + "GenomicRanges", + "S4Vectors", + "SummarizedExperiment", + "methods", + "stats", + "utils" + ], + "Hash": "48880101d1aacf03683ed4cff15d1192" + }, "SparseArray": { "Package": "SparseArray", "Version": "1.6.0", @@ -1114,6 +1131,16 @@ ], "Hash": "15e9634c0fcd294799e9b2e929ed1b86" }, + "getopt": { + "Package": "getopt", + "Version": "1.20.4", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "stats" + ], + "Hash": "ed33b16c6d24f7ced1d68877ac2509ee" + }, "ggplot2": { "Package": "ggplot2", "Version": "3.5.1", @@ -1613,6 +1640,18 @@ ], "Hash": "d413e0fef796c9401a4419485f709ca1" }, + "optparse": { + "Package": "optparse", + "Version": "1.7.5", + "Source": "Repository", + "Repository": "RSPM", + "Requirements": [ + "R", + "getopt", + "methods" + ], + "Hash": "ce5f8381cd2c38d1fc14c83d8b21efd0" + }, "paintmap": { "Package": "paintmap", "Version": "1.0", From 79656911c10ac1ead34f22487ac0bb99ff06015b Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 13:24:47 -0600 Subject: [PATCH 07/15] add documentation --- analyses/cell-type-consensus/README.md | 65 ++++++++++++++++--- .../assign-consensus-celltypes.sh | 4 +- .../cell-type-consensus/scripts/README.md | 5 ++ 3 files changed, 62 insertions(+), 12 deletions(-) mode change 100644 => 100755 analyses/cell-type-consensus/assign-consensus-celltypes.sh diff --git a/analyses/cell-type-consensus/README.md b/analyses/cell-type-consensus/README.md index 3346815b9..2fd131bae 100644 --- a/analyses/cell-type-consensus/README.md +++ b/analyses/cell-type-consensus/README.md @@ -3,7 +3,7 @@ This module explores creating rules that can be used to identify a consensus cell type label. Specifically, the cell type annotations obtained from both `SingleR` and `CellAssign` will be used to create a single cell type label in an ontology aware manner. -## Description +## Creating a reference for consensus cell types The goal of this module is to create a reference that can be used to define an ontology aware consensus cell type label for all cells across all ScPCA samples. This module performs a series of steps to accomplish that goal: @@ -25,23 +25,70 @@ If that is the case all other LCA terms are removed and `hematopoietic precursor - When the LCA is `epithelial cell` and the annotation from `BlueprintEncodeData` is `Epithelial cells`, then `epithelial cell` is used as the consensus label. - If the LCA is `bone cell`, `lining cell`, `blood cell`, `progenitor cell`, or `supporting cell`, no consensus label is defined. +See the [`scripts/README.md`](./scripts/README.md) for instructions on running the individual scripts used to generate the reference. -## Usage +## Assigning consensus cell types for ScPCA samples -See the [`scripts/README.md`](./scripts/README.md) for instructions on running the scripts in this module. +The `assign-consensus-celltypes.sh` workflow can be used to assign a consensus cell type for all samples in ScPCA. +This workflow outputs a single TSV file with cell type annotations for all cells in ScPCA (excluding cell line samples). +Cell type annotations assigned using `SingleR` with the `BlueprintEncodeData` reference and `CellAssign` using the `PanglaoDB` reference are included along side the assigned consensus cell type annotation and ontology identifier. -## Input files +To run this workflow use the following command: -TBD +```sh +./assign-consensus-celltypes.sh +``` -## Output files +### Input files -TBD + +The `assign-consensus-celltypes.sh` workflow requires the processed `SingleCellExperiment` objects (`_processed.rds`) for all ScPCA samples. +These files were obtained using the `download-data.py` script: + +```sh +# download SCE objects +./download-data.py +``` + +This workflow also requires two reference files, `panglao-cell-type-ontologies.tsv` and `consensus-cell-type-reference.tsv`. +See [Creating a reference for consensus cell types](#creating-a-reference-for-consensus-cell-types) and the [README.md in the references directory](./references/README.md) to learn more about the content of these files. + +### Output files + +Running the `assign-consensus-celltypes.sh` workflow will generate the following output files in `results`. + +``` +results +├── scpca-consensus-celltype-assignments.tsv +├── original-celltype-assignments + ├── _celltype-assignments.tsv + └── _celltype-assignments.tsv +``` + +The `original-celltyp-assignments` folder contains a single TSV file for each library in ScPCA, except for libraries obtained from cell lines. +These TSV files have the cell type annotations from running `SingleR` and `CellAssign` that can be found in the `colData` of the processed SCE objects. + +The `scpca-consensus-celltype-assignments.tsv` file contains cell type annotations for all cells in all ScPCA samples with the following columns: + +| | | +| --- | --- | +| `project_id` | ScPCA project id | +| `sample_id` | ScPCA sample id | +| `library_id` | ScPCA library id | +| `barcodes` | cell barcode | +| `singler_celltype_ontology` | Cell type ontology term assigned by `SingleR` | +| `singler_celltype_annotation` | Name associated with cell type ontology term assigned by `SingleR`; this term is equivalent to the `label.main` term in the `BlueprintEncodeData` reference | +| `cellassign_celltype_annotation` | Cell type assigned by `CellAssign`; this term is the original term found in the `PanglaoDB` reference file | +| `panglao_ontology` | Cell type ontology term associated with the term found in `cellassign_celltype_annotation` column | +| `panglao_annotation` | Name associated with the cell type ontology term in `panglao_ontology` | +| `blueprint_annotation_fine` | Fine grained cell type annotation (`label.fine`) from `BlueprintEncodeData` associated with the `singler_celltype_ontology` term | +| `consensus_ontology` | Cell type ontology term assigned as the consensus cell type | +| `consensus_annotation` | Name associated with the assigned consensus cell type in `consensus_ontology` | ## Software requirements -TBD +This module uses `renv` to manage software dependencies. ## Computational resources -TBD +This module does not require compute beyond what is generally available on a laptop. diff --git a/analyses/cell-type-consensus/assign-consensus-celltypes.sh b/analyses/cell-type-consensus/assign-consensus-celltypes.sh old mode 100644 new mode 100755 index dd6c7b643..04a4ae063 --- a/analyses/cell-type-consensus/assign-consensus-celltypes.sh +++ b/analyses/cell-type-consensus/assign-consensus-celltypes.sh @@ -4,10 +4,8 @@ # The existing cell type annotations from SingleR and CellAssign are saved to a TSV file for each sample # Then all TSV files are combined into a single file and consensus cell types are assigned -# Usage: ./evaluate-clusters.sh +# Usage: ./assign-consensus-celltypes.sh -# to skip clustering and calculating metrics again: -# skip_metrics=1 ./evaluate-clusters.sh set -euo pipefail diff --git a/analyses/cell-type-consensus/scripts/README.md b/analyses/cell-type-consensus/scripts/README.md index e61b7e5cc..c30058410 100644 --- a/analyses/cell-type-consensus/scripts/README.md +++ b/analyses/cell-type-consensus/scripts/README.md @@ -13,3 +13,8 @@ Ontology terms and labels along with the `cell type` label from the reference fi 3. `02-prepare-consensus-reference.R`: This script is used to create a table with all consensus cell types. The output table will contain one row for each combination of cell types in `PanglaoDB` and `BlueprintEncodeData` from `celldex` where a consensus cell type was identified. If the combination is not included in the reference file, then no consensus cell type is assigned and can be set to "Unknown". + +4. `03-save-coldata.R`: This script is used to grab the cell type annotations from the `colData` of an individual processed SCE object and save the output to a TSV file. + +5. `04-combine-celltype-tables.R`: This script is used to combine individual TSV files with cell type annotations (output by `03-save-coldata.R`) into a single TSV file. +The consensus cell type reference is used to assign consensus cell types to all cells in the combined data frame and saved in the output TSV file. From 3f9183de6aaed87d9920e4ad104f1dbcdf2794af Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Wed, 8 Jan 2025 14:00:31 -0600 Subject: [PATCH 08/15] add to ci --- .github/workflows/run_cell-type-consensus.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/run_cell-type-consensus.yml b/.github/workflows/run_cell-type-consensus.yml index e3d110e04..ddd13b0b9 100644 --- a/.github/workflows/run_cell-type-consensus.yml +++ b/.github/workflows/run_cell-type-consensus.yml @@ -53,3 +53,4 @@ jobs: run: | cd ${MODULE_PATH} # run module script(s) here + ./assign-consensus-celltypes.sh From 2bbacc3c5f2c0cab22b79718f317f960b1e29ada Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 09:56:20 -0600 Subject: [PATCH 09/15] change workflow -> script --- analyses/cell-type-consensus/README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/analyses/cell-type-consensus/README.md b/analyses/cell-type-consensus/README.md index 2fd131bae..9789083d4 100644 --- a/analyses/cell-type-consensus/README.md +++ b/analyses/cell-type-consensus/README.md @@ -29,11 +29,11 @@ See the [`scripts/README.md`](./scripts/README.md) for instructions on running t ## Assigning consensus cell types for ScPCA samples -The `assign-consensus-celltypes.sh` workflow can be used to assign a consensus cell type for all samples in ScPCA. -This workflow outputs a single TSV file with cell type annotations for all cells in ScPCA (excluding cell line samples). +The `assign-consensus-celltypes.sh` script can be used to assign a consensus cell type for all samples in ScPCA. +This script outputs a single TSV file with cell type annotations for all cells in ScPCA (excluding cell line samples). Cell type annotations assigned using `SingleR` with the `BlueprintEncodeData` reference and `CellAssign` using the `PanglaoDB` reference are included along side the assigned consensus cell type annotation and ontology identifier. -To run this workflow use the following command: +To run this script use the following command: ```sh ./assign-consensus-celltypes.sh @@ -42,7 +42,7 @@ To run this workflow use the following command: ### Input files -The `assign-consensus-celltypes.sh` workflow requires the processed `SingleCellExperiment` objects (`_processed.rds`) for all ScPCA samples. +The `assign-consensus-celltypes.sh` script requires the processed `SingleCellExperiment` objects (`_processed.rds`) for all ScPCA samples. These files were obtained using the `download-data.py` script: ```sh @@ -50,12 +50,12 @@ These files were obtained using the `download-data.py` script: ./download-data.py ``` -This workflow also requires two reference files, `panglao-cell-type-ontologies.tsv` and `consensus-cell-type-reference.tsv`. +This script also requires two reference files, `panglao-cell-type-ontologies.tsv` and `consensus-cell-type-reference.tsv`. See [Creating a reference for consensus cell types](#creating-a-reference-for-consensus-cell-types) and the [README.md in the references directory](./references/README.md) to learn more about the content of these files. ### Output files -Running the `assign-consensus-celltypes.sh` workflow will generate the following output files in `results`. +Running the `assign-consensus-celltypes.sh` script will generate the following output files in `results`. ``` results From 6f4f1a05ee90d3e663beaa6112bf764e5253af93 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 09:56:52 -0600 Subject: [PATCH 10/15] remove here::here --- analyses/cell-type-consensus/scripts/03-save-coldata.R | 2 -- .../cell-type-consensus/scripts/04-combine-celltype-tables.R | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/analyses/cell-type-consensus/scripts/03-save-coldata.R b/analyses/cell-type-consensus/scripts/03-save-coldata.R index dec64c46d..45568956f 100644 --- a/analyses/cell-type-consensus/scripts/03-save-coldata.R +++ b/analyses/cell-type-consensus/scripts/03-save-coldata.R @@ -2,8 +2,6 @@ # This script is used to grab the colData from a SCE object and save it as a TSV file -project_root <- here::here() - library(optparse) option_list <- list( diff --git a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R index 78adffd75..59e199e07 100644 --- a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R +++ b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R @@ -8,7 +8,7 @@ # consensus_annotation: human readable name associated with the consensus label # consensus_ontology: CL ontology term for the consensus cell type -project_root <- here::here() +project_root <- rprojroot::find_root(rprojroot::is_git_root) library(optparse) From 6b7c34213856e31373f601b097140382c4df40e1 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 10:11:46 -0600 Subject: [PATCH 11/15] account for multiplexed libraries --- .../cell-type-consensus/scripts/03-save-coldata.R | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/analyses/cell-type-consensus/scripts/03-save-coldata.R b/analyses/cell-type-consensus/scripts/03-save-coldata.R index 45568956f..84d431b11 100644 --- a/analyses/cell-type-consensus/scripts/03-save-coldata.R +++ b/analyses/cell-type-consensus/scripts/03-save-coldata.R @@ -39,11 +39,16 @@ sce <- readr::read_rds(opt$sce_file) # extract ids library_id <- metadata(sce)$library_id -sample_id <- metadata(sce)$sample_id +# account for multiplexed libraries that have multiple samples +# for now just combine sample ids into a single string and don't worry about demultiplexing +sample_id <- metadata(sce)$sample_id |> + paste0(collapse = ";") project_id <- metadata(sce)$project_id # check if cell line since cell lines don't have any cell type assignments -is_cell_line <- metadata(sce)$sample_type == "cell line" +# account for having more than one sample and a list of sample types +# all sample types should be the same theoretically +is_cell_line <- all(metadata(sce)$sample_type == "cell line") # only create and write table for non-cell line samples if(!is_cell_line){ @@ -57,8 +62,10 @@ if(!is_cell_line){ library_id = library_id ) |> dplyr::select( - ends_with("id"), - "barcodes", + project_id, + sample_id, + library_id, + barcodes, contains("celltype") # get both singler and cellassign with ontology ) From 939103f0a95c4256c873815fd45b088fdebe2ee5 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 10:12:00 -0600 Subject: [PATCH 12/15] remove module_dir variable --- .../assign-consensus-celltypes.sh | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/analyses/cell-type-consensus/assign-consensus-celltypes.sh b/analyses/cell-type-consensus/assign-consensus-celltypes.sh index 04a4ae063..facc31ebf 100755 --- a/analyses/cell-type-consensus/assign-consensus-celltypes.sh +++ b/analyses/cell-type-consensus/assign-consensus-celltypes.sh @@ -11,21 +11,18 @@ set -euo pipefail # navigate to where script lives cd $(dirname "$0") -module_dir=$(pwd) +#module_dir=$(pwd) -data_dir="${module_dir}/../../data/current" +data_dir="../../data/current" # path to save consensus results -scpca_consensus_assignments_file="${module_dir}/results/scpca-consensus-celltype-assignments.tsv" +scpca_consensus_assignments_file="results/scpca-consensus-celltype-assignments.tsv" # directory to store all individual tsv files -celltype_tsv_dir="${module_dir}/results/original-celltype-assignments" +celltype_tsv_dir="results/original-celltype-assignments" mkdir -p ${celltype_tsv_dir} -# define scripts and notebook directories -scripts_dir="${module_dir}/scripts" - # define reference input files -panglao_ref_file="${module_dir}/references/panglao-cell-type-ontologies.tsv" -consensus_ref_file="${module_dir}/references/consensus-cell-type-reference.tsv" +panglao_ref_file="references/panglao-cell-type-ontologies.tsv" +consensus_ref_file="references/consensus-cell-type-reference.tsv" # run script to export tsv file on all processed objects for sce_file in $data_dir/*/SCPCS*/*_processed.rds; do @@ -35,7 +32,7 @@ for sce_file in $data_dir/*/SCPCS*/*_processed.rds; do echo "Grabbing cell types for ${library_id}" # get celltypes as tsv file - Rscript $scripts_dir/03-save-coldata.R \ + Rscript scripts/03-save-coldata.R \ --sce_file $sce_file \ --output_file ${celltype_tsv_dir}/${library_id}_celltype-assignments.tsv @@ -43,7 +40,7 @@ done echo "Combining TSVs and adding consensus labels" # run script to combine all tsv files and assign consensus cell types -Rscript $scripts_dir/04-combine-celltype-tables.R \ +Rscript scripts/04-combine-celltype-tables.R \ --celltype_tsv_dir $celltype_tsv_dir \ --panglao_ref_file $panglao_ref_file \ --consensus_ref_file $consensus_ref_file \ From bcb16a56a71b3506ad17ee3e23428c35261f3d4e Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 10:24:56 -0600 Subject: [PATCH 13/15] compress output --- analyses/cell-type-consensus/assign-consensus-celltypes.sh | 2 +- .../scripts/04-combine-celltype-tables.R | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/analyses/cell-type-consensus/assign-consensus-celltypes.sh b/analyses/cell-type-consensus/assign-consensus-celltypes.sh index facc31ebf..c48e5c680 100755 --- a/analyses/cell-type-consensus/assign-consensus-celltypes.sh +++ b/analyses/cell-type-consensus/assign-consensus-celltypes.sh @@ -15,7 +15,7 @@ cd $(dirname "$0") data_dir="../../data/current" # path to save consensus results -scpca_consensus_assignments_file="results/scpca-consensus-celltype-assignments.tsv" +scpca_consensus_assignments_file="results/scpca-consensus-celltype-assignments.tsv.gz" # directory to store all individual tsv files celltype_tsv_dir="results/original-celltype-assignments" mkdir -p ${celltype_tsv_dir} diff --git a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R index 59e199e07..602340f56 100644 --- a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R +++ b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R @@ -34,7 +34,8 @@ option_list <- list( make_option( opt_str = c("--output_file"), type = "character", - help = "Path to file where combined TSV file will be saved, must end in `.tsv`" + help = "Path to file where combined TSV file will be saved. + File name must end in either `.tsv` or `.tsv.gz` to save a compressed TSV file" ) ) @@ -46,7 +47,8 @@ opt <- parse_args(OptionParser(option_list = option_list)) # make sure reference files exist stopifnot( "panglao reference file does not exist" = file.exists(opt$panglao_ref_file), - "cell type consensus reference file does not exist" = file.exists(opt$consensus_ref_file) + "cell type consensus reference file does not exist" = file.exists(opt$consensus_ref_file), + "output file must end in `.tsv` or `.tsv.gz`" = stringr::str_detect(opt$output_file, ".tsv|.tsv.gz") ) # read in ref files From 965e445f53f1d5973cf4c654d60eb4a9a4491926 Mon Sep 17 00:00:00 2001 From: Ally Hawkins <54039191+allyhawkins@users.noreply.github.com> Date: Thu, 9 Jan 2025 12:27:08 -0600 Subject: [PATCH 14/15] Make file search more specific Co-authored-by: Joshua Shapiro --- analyses/cell-type-consensus/assign-consensus-celltypes.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/analyses/cell-type-consensus/assign-consensus-celltypes.sh b/analyses/cell-type-consensus/assign-consensus-celltypes.sh index c48e5c680..83897d93b 100755 --- a/analyses/cell-type-consensus/assign-consensus-celltypes.sh +++ b/analyses/cell-type-consensus/assign-consensus-celltypes.sh @@ -25,7 +25,7 @@ panglao_ref_file="references/panglao-cell-type-ontologies.tsv" consensus_ref_file="references/consensus-cell-type-reference.tsv" # run script to export tsv file on all processed objects -for sce_file in $data_dir/*/SCPCS*/*_processed.rds; do +for sce_file in $data_dir/SCPCP*/SCPCS*/*_processed.rds; do # define library ID library_id=$(basename $sce_file | sed 's/_processed.rds$//') From d7b93edcc43a269f980eddcb3fbf3a8e947bc176 Mon Sep 17 00:00:00 2001 From: Ally Hawkins Date: Thu, 9 Jan 2025 13:12:32 -0600 Subject: [PATCH 15/15] try different rprojroot --- .../cell-type-consensus/scripts/04-combine-celltype-tables.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R index 602340f56..453f2d4a9 100644 --- a/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R +++ b/analyses/cell-type-consensus/scripts/04-combine-celltype-tables.R @@ -8,7 +8,7 @@ # consensus_annotation: human readable name associated with the consensus label # consensus_ontology: CL ontology term for the consensus cell type -project_root <- rprojroot::find_root(rprojroot::is_git_root) +project_root <- rprojroot::find_root(rprojroot::has_dir(".github")) library(optparse)