GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - ssokolova01/Bone_Marrow_Single-Cell_RNA-seq_Analysis: Single-Cell RNA-seq Analysis of bone marrow sample data from the CZ CELLxGENE Discover platform using the Python/Scanpy stack.

BranchesTags
Open more actions menu

Latest commit

 

History

6 Commits
6 Commits

Folders and files

NameName
Last commit message
Last commit date
.gitattributes
.gitattributes
 
 
README.md
README.md
 
 
sc_Blood_code.ipynb
sc_Blood_code.ipynb
 
 
sc_blood_code.py
sc_blood_code.py
 
 

Repository files navigation

Single-Cell_Internship_HackBio

Project Stage 2: Single-Cell RNA-Seq Analysis of Bone Marrow Sample Using Standard Scanpy Workflow

Objective: Sample origin identification and biological interpretation of cell types found in the single-cell dataset.


Repository Contents

  • sc_Blood_code.ipynb: Full Jupyter Notebook containing the step-by-step analysis, exploratory data plots and inline cell annotations.
  • sc_blood_code.py: Clean executable Python script of the processing pipeline.

Key Dependencies & Tools

  • Language: Python
  • Core Framework: Scanpy
  • Data Science Stack: AnnData, Decoupler, Pandas, Seaborn

COMPUTATIONAL ANALYSIS WORKFLOW

0. Tools And Dataset Preparation: Packages and Libaries Installation & Loading and Exploring Dataset Structure

  • Tools Installation:
    • Single-Cell Genomics & Annotation Frameworks: scanpy (v1.12), anndata, celltypist (automated classification), decoupler (marker enrichment), igraph, fa2-modified (force-directed graph abstractions).
    • Core Data Science & Visualization Stack: pandas (structured dataframes), seaborn (statistical graphics).
  • Data import:
    • .h5_ad file

1. Pre-processing: Quality Control & Normalization

  • Quality Control:
    • Removed duplicate gene names from the raw matrix.
    • Assessed cell quality metrics by tracking genes and UMI counts per cell alongside mitochondrial (MT), ribosomal (RIBO), and hemoglobin (HB) gene content.
    • Established initial strict filtering thresholds at MT < 5%, RB < 10%, and HB < 5%.
    • Note on Sample Integrity: Programmatic filtering was ultimately bypassed due to exceptional sample purity and minimal contamination (MT genes registered < 2%; RIBO genes < 5%; no HB genes were detected).
    • Cleared doublets from the dataset utilizing scrublet.
  • Normalization & Feature Selection:
    • Standardized single-cell expression profiles across the dataset.
    • Executed highly variable gene (HVG) selection, isolating the top 1,000 genes for downstream computational steps.

2. Cell Population Analysis: Dimensionality Reduction & Clustering

  • Dimensionality Reduction:
    • Performed Principal Component Analysis (PCA) on the gene expression space for initial feature reduction.
  • Clustering & Visualisation:
    • Constructed a cell neighborhood graph based on reduced components.
    • Applied Leiden clustering to partition cell populations according to shared transcriptional profiles.
    • Visualized complex population metrics utilizing a 2D UMAP projection.

3. Annotation: Cell Type Identification

  • Marker Discovery:
    • Executed gene set enrichment analysis leveraging canonical bone marrow markers retrieved from the PanglaoDB database.
  • Lineage Mapping:
    • Matched target clusters to definitive, known cell types using the decoupler framework.
    • Visualized all final annotated cell-type clusters directly on the UMAP layout to isolate the root sample mislabeling anomalies.

Findings

image image
  • Figure 1 (Left): Unsupervised Leiden clustering (resolution 0.3) mapping 8 highly distinct cellular neighborhoods in UMAP space.
  • Figure 2 (Right): Definitive cell-type annotations mapping lineages including Monocytes, Neutrophils, Nuocytes, Plasma Cells, Platelets, and Naive B/T Cell fractions.

8 unique clusters have been identified.

List of the annotated clusters:

Neutrophils, Gamma delta T cells (γδ T Lymphocytes), Nuocytes (Type 2 Innate Lymphoid Cells, ILC2), Natural Killer (NK) cells, B cells naïve, Platelets, Plasma cells, Monocytes.

Neutrophils: white blood cell, provides immune response to infection within phagocytosis; boost response of other immune cells.

Gamma delta T cells: a unique and less abundant subset of T cells in peripheral blood; vital to the initial inflammatory and immune responses; bridge innate and adaptive immunity. Can be present in bone marrow.

Nuocytes: defends against parasitic worms and contributes to allergic responses (inflammation); involved in tissue repair and remodelling; enriched in mucosal organs, (lungs and intestines), lymphoid organs (spleen and mesenteric lymph nodes).

Natural Killer (NK) cells: kill virus-infected cells and cancer cells without prior activation; destroy target cells releasing perforins and granzymes. Develop and mature in bone marrow, mature are in bloodstream and other, mostly lymphoid, organs.

B cells naïve: mature B cells unfamiliar with antigen; undergo positive and negative selection processes in bone marrow and spleen to distinguish antigens form self-tissues; migrate to spleen and lymph nodes after maturation; can be found in the blood.

Platelets: cell fragments from megakaryocyte circulating in blood; responsible for clotting and wound healing; promote tissue regeneration.

Plasma cells: white blood cells that develop from activated B lymphocytes (B cells); responsible for producing antibodies.

Monocytes: the largest white blood cells; detect and respond to pathogens, involved in inflammation, tissue repair and maintain balance of the immune system; transform into macrophages and dendritic cells when migrate in tissues.

(MSD Manuals, Cellular Components of the Immune System; Miltenyi Biotec MACS Handbook)

Biological Interpretation

The set of the found cell clusters corresponds to peripheral blood (leukocyte-enriched fraction; RBCs removed during scRNA-seq sample preparation).

Reasons to reject bone marrow origin of sequenced sample.

Bone marrow of the healthy adult contains blood-forming hematopoietic stem cells (HSC) and structural mesenchymal stem cells (MSC) lineage populations. From MSC develop stromal lineages including mesenchymal stromal cells, osteoblasts (bone-forming cells), and adipocytes (fat cells). Principal cell lineages of the bone marrow are myeloid and lymphoid lineages, which starts from the myeloid and lymphoid progenitor cells. Common myeloid progenitor cell then proceeds into megakaryocytic, erythroid and myeloid lineages which start from megakaryocyte-erythrocyte progenitor cell and granulocyte-monocyte progenitor cell. Common lymphoid progenitor is responsible for all the lymphoid lineage cells from lymphoblast to lymphocytes and NK cells. Lineages start from blast stage, then they progress in differentiation, and their names depend on cell line. (Human Cell Atlas; Mahalingaiah et al.)

There are no Hematopoietic Stem and Progenitor Cells (HSPCs) clusters or immature blood cells (e.g., myeloblasts, lymphoblasts, megakaryocytes, erythroblasts, reticulocytes) found in the analysed sample. Detection of stem cells, progenitors and immature forms in the sample would be a strong indicator of its bone marrow origine. In opposite, all found cell types are mature and highly differentiated, even though some of them could be found in the bone marrow in certain stages and conditions. Also, no non-hematopoietic stromal cells of supporting microenvironment were detected. In opposite, found cell types include lymphocytes, monocytes, neutrophils and platelets. (Human Cell Atlas; Mahalingaiah et al.)

Distribution of the healthy bone marrow usually represents the abundance of the neutrophilic cell lineage, including immature forms such as promyelocytes, myelocytes and neutrophils; there is also a high level of erythroblasts; lymphocytes are present in smaller quantities. Thus, the distribution of cells in the studied sample differs from the typical cell distribution in bone marrow.

The identified cell type which is the most atypical for bone marrow is nuocytes, especially regarding their high level in the studied sample.

Conclusion

Reference context. Apart from erythrocytes (red blood cells), the typical peripheral blood contains leukocytes (neutrophils, lymphocytes, monocytes, eosinophils, basophils) and thrombocytes (platelets). Eosinophils and basophils have very low level or can be absent. Neutrophils, lymphocytes, monocytes and platelets are essential. In healthy adult human blood, neutrophils prevail over lymphocytes, and platelets prevail over white blood cells.

Single cell analysis insights.

Cluster proportions and Cell type deviations. According to the cluster proportions, the most abundant identified cell types are Gamma delta T cells, Natural Killers cells (NK cells) and Nuocytes. The least represented is platelets cluster. Overall, the most represented cells belong to lymphocytes (Gamma delta T cells, NK cells, B cells naive and plasma cells) and nuocytes also have lymphoid origin. Thus, clusters of the lymphoid lineage cells predominate in number and are highly populated.

Cell type deviations. Cell type proportion is altered. There is a lymphocytes expansion. Neutrophils are dramatically lower represented than lymphocytes. High level of non-blood-typical cell clusters (nuocytes, NK cells, gamma delta T cells, plasma cells) appears. Both B naive cells and plasma cells occurrence can indirectly indicate high antigen level (e.g., pathogen) and the need to produce a lot of antibodies.

Given their unique nature as anucleate cell fragments, the low occurrence of platelets is difficult to interpret based solely on the clustering results.

Functional state. Immune system activation, mostly innate immune system (abundant cytotoxic gamma delta T cells and ILC2s—first responders). Inflammation, most likely viral infectious nature. Expression of CCL genes coding chemokines and IL genes coding cytokines, which are the markers of an active infection inflammation process. Also detected: increased monocytes for antigen presentation, naive B cells for pathogen recognition, and plasma cells driving antibody production. (Suen et al., 2025; Hams & Fallon, 2012)

Conclusion. The sample represents a peripheral blood leukocyte preparation, as evidenced by the presence of mature immune cells (lymphocytes, monocytes, neutrophils) and absence of hematopoietic stem/progenitor cells characteristic of bone marrow. Erythrocytes are not detected in scRNA-seq data due to standard sample processing and the lack of nuclear RNA in mature red blood cells. Cell cluster qualitative and quantitative distribution presents peripheral blood in activated immune system status and acute intense inflammation process, most probably caused by viral infection. Further functional gene analysis is required to validate the nature of the pathology.

Literature:

Hams & Fallon, 2012

Human Cell Atlas

Mahalingaiah et al., 2018

Miltenyi Biotec MACS Handbook

MSD Manuals, Cellular Components of the Immune System

Suen et al., 2025

About

Single-Cell RNA-seq Analysis of bone marrow sample data from the CZ CELLxGENE Discover platform using the Python/Scanpy stack.

Topics

bone-marrowcell-annotationscanpyscrna-seqscrna-seq-analysis

Resources

Readme
Activity

Stars

1 star

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.