Skip to main content

Thank you for visiting nature.com. You are using a browser version with limited support for CSS. To obtain the best experience, we recommend you use a more up to date browser (or turn off compatibility mode in Internet Explorer). In the meantime, to ensure continued support, we are displaying the site without styles and JavaScript.

  • Protocol
  • Published:

NovoSpaRc: flexible spatial reconstruction of single-cell gene expression with optimal transport

Abstract

Single-cell RNA-sequencing (scRNA-seq) technologies have revolutionized modern biomedical sciences. A fundamental challenge is to incorporate spatial information to study tissue organization and spatial gene expression patterns. Here, we describe a detailed protocol for using novoSpaRc, a computational framework that probabilistically assigns cells to tissue locations. At the core of this framework lies a structural correspondence hypothesis, that cells in physical proximity share similar gene expression profiles. Given scRNA-seq data, novoSpaRc spatially reconstructs tissues based on this hypothesis, and optionally, by including a reference atlas of marker genes to improve reconstruction. We describe the novoSpaRc algorithm, and its implementation in an open-source Python package (https://pypi.org/project/novosparc). NovoSpaRc maps a scRNA-seq dataset of 10,000 cells onto 1,000 locations in <5 min. We describe results obtained using novoSpaRc to reconstruct the mouse organ of Corti de novo based on the structural correspondence assumption and human osteosarcoma cultured cells based on marker gene information, and provide a step-by-step guide to Drosophila embryo reconstruction in the Procedure to demonstrate how these two strategies can be combined.

This is a preview of subscription content, access via your institution

Access options

Buy this article

Prices may be subject to local taxes which are calculated during checkout

Fig. 1: Schematic representation of the novoSpaRc algorithm.
Fig. 2: NovoSpaRc successfully reconstructs de novo the organ of Corti.
Fig. 3: Spatial reconstruction of osteosarcoma cultured cells using marker gene information.
Fig. 4: Computing times of the setup and reconstruction steps.
Fig. 5: Configure target space.
Fig. 6: Spatial expression based on reference atlas and novoSpaRc reconstruction.
Fig. 7: Structural correspondence and Moran’s I score for the Drosophila reference atlas.
Fig. 8: Cross-validation and self-consistency for selecting alpha-linear.
Fig. 9: Inspecting cell-to-location OT values.
Fig. 10: Analysis of spatially informative genes.
Fig. 11: Extracting spatial archetypes.

Similar content being viewed by others

Data availability

All data analyzed within this protocol are publicly available. The osteosarcoma dataset14 (Fig. 3) and the organ of Corti data42 (Fig. 2) can be downloaded from the accompanying supplementary files of their corresponding papers. The Drosophila embryo scRNA-seq data27 used in the Procedure was acquired from the GEO database with accession number GSE95025, and the reference Berkeley Drosophila Transcription Network Project (BDTNP) dataset can be downloaded directly from the BDTNP webpage (ref. 46 and FlyBase, http://flybase.org/reports/FBlc0003350.html). The whole-kidney dataset47 used for benchmarking runtimes (Fig. 4) is available in the GEO database with accession number GSE107585.

Code availability

NovoSpaRc is available as a Python package at https://pypi.org/project/novosparc/, and its source code is available on GitHub (https://github.com/rajewsky-lab/novosparc) and on Zenodo49.

References

  1. Aldridge, S. & Teichmann, S. A. Single cell transcriptomics comes of age. Nat. Commun. 11, 4307 (2020).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  2. Kulkarni, A., Anderson, A. G., Merullo, D. P. & Konopka, G. Beyond bulk: a review of single cell transcriptomics methodologies and applications. Curr. Opin. Biotechnol. 58, 129–136 (2019).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  3. Macosko, E. Z. et al. Highly parallel genome-wide expression profiling of individual cells using nanoliter droplets. Cell 161, 1202–1214 (2015).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  4. Klein, A. M. et al. Droplet barcoding for single-cell transcriptomics applied to embryonic stem cells. Cell 161, 1187–1201 (2015).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  5. Birnbaum, K. D. Power in numbers: single-cell RNA-seq strategies to dissect complex tissues. Annu. Rev. Genet. 52, 203–221 (2018).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  6. Buettner, F. et al. Computational analysis of cell-to-cell heterogeneity in single-cell RNA-sequencing data reveals hidden subpopulations of cells. Nat. Biotechnol. 33, 155–160 (2015).

    Article  CAS  PubMed  Google Scholar 

  7. Plasschaert, L. W. et al. A single-cell atlas of the airway epithelium reveals the CFTR-rich pulmonary ionocyte. Nature 560, 377–381 (2018).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  8. Saunders, A. et al. Molecular diversity and specializations among the cells of the adult mouse brain. Cell 174, 1015–1030.e16 (2018).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  9. Trapnell, C. Defining cell types and states with single-cell genomics. Genome Res. 25, 1491–1498 (2015).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  10. Wagner, D. E. & Klein, A. M. Lineage tracing meets single-cell omics: opportunities and challenges. Nat. Rev. Genet. 21, 410–427 (2020).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  11. Cannoodt, R., Saelens, W. & Saeys, Y. Computational methods for trajectory inference from single-cell transcriptomics. Eur. J. Immunol. 46, 2496–2506 (2016).

    Article  CAS  PubMed  Google Scholar 

  12. Moor, A. E. et al. Spatial reconstruction of single enterocytes uncovers broad zonation along the intestinal villus axis. Cell 175, 1156–1167.e15 (2018).

    Article  CAS  PubMed  Google Scholar 

  13. Puram, S. V. et al. Single-cell transcriptomic analysis of primary and metastatic tumor ecosystems in head and neck cancer. Cell 171, 1611–1624.e24 (2017).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  14. Xia, C., Fan, J., Emanuel, G., Hao, J. & Zhuang, X. Spatial transcriptome profiling by MERFISH reveals subcellular RNA compartmentalization and cell cycle-dependent gene expression. Proc. Natl Acad. Sci. USA 116, 19490–19499 (2019).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  15. Sun, S., Zhu, J. & Zhou, X. Statistical analysis of spatial expression patterns for spatially resolved transcriptomic studies. Nat. Methods 17, 193–200 (2020).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  16. Eng, C.-H. L. et al. Transcriptome-scale super-resolved imaging in tissues by RNA seqFISH. Nature 568, 235–239 (2019).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  17. Wang, X. et al. Three-dimensional intact-tissue sequencing of single-cell transcriptional states. Science 361, (2018).

  18. Gumbleton, M. et al. Spatial expression and functionality of drug transporters in the intact lung: objectives for further research. Adv. Drug Deliv. Rev. 63, 110–118 (2011).

    Article  CAS  PubMed  Google Scholar 

  19. Arnol, D., Schapiro, D., Bodenmiller, B., Saez-Rodriguez, J. & Stegle, O. Modeling cell-cell interactions from spatial molecular data with spatial variance component analysis. Cell Rep. 29, 202–211.e6 (2019).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  20. Teves, J. M. & Won, K. J. Mapping cellular coordinates through advances in spatial transcriptomics technology. Mol. Cells 43, 591–599 (2020).

    CAS  PubMed  PubMed Central  Google Scholar 

  21. Goltsev, Y. et al. Deep profiling of mouse splenic architecture with CODEX multiplexed imaging. Cell 174, 968–981.e15 (2018).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  22. Qian, X. et al. Probabilistic cell typing enables fine mapping of closely related cell types in situ. Nat. Methods 17, 101–106 (2020).

    Article  CAS  PubMed  Google Scholar 

  23. Rodriques, S. G. et al. Slide-seq: a scalable technology for measuring genome-wide expression at high spatial resolution. Science 363, 1463–1467 (2019).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  24. Stickels, R. R. et al. Highly sensitive spatial transcriptomics at near-cellular resolution with Slide-seqV2. Nat. Biotechnol. https://doi.org/10.1038/s41587-020-0739-1 (2020).

  25. Satija, R., Farrell, J. A., Gennert, D., Schier, A. F. & Regev, A. Spatial reconstruction of single-cell gene expression data. Nat. Biotechnol. 33, 495–502 (2015).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  26. Achim, K. et al. High-throughput spatial mapping of single-cell RNA-seq data to tissue of origin. Nat. Biotechnol. 33, 503–509 (2015).

    Article  CAS  PubMed  Google Scholar 

  27. Karaiskos, N. et al. The Drosophila embryo at single-cell transcriptome resolution. Science 358, 194–199 (2017).

    Article  CAS  PubMed  Google Scholar 

  28. Okochi, Y., Sakaguchi, S., Nakae, K., Kondo, T. & Naoki, H. Model-based prediction of spatial gene expression via generative linear mapping. Nat. Commun. 12, 3731 (2021).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  29. Biancalani, T. et al. Deep learning and alignment of spatially-resolved whole transcriptomes of single cells in the mouse brain with Tangram. Preprint at bioRxiv https://doi.org/10.1101/2020.08.29.272831 (2020).

  30. Nitzan, M., Karaiskos, N., Friedman, N. & Rajewsky, N. Gene expression cartography. Nature 576, 132–137 (2019).

    Article  CAS  PubMed  Google Scholar 

  31. Peyré, G. & Cuturi, M. Computational optimal transport: with applications to data science. Found. Trends Mach. Learn. 11, 355–607 (2019).

    Article  Google Scholar 

  32. Villani, C. Topics in Optimal Transportation (American Mathematical Society, 2003).

  33. Durruthy-Durruthy, R. et al. Reconstruction of the mouse otocyst and early neuroblast lineage at single-cell resolution. Cell 157, 964–978 (2014).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  34. Stickels, R. R. et al. Sensitive spatial genome wide expression profiling at cellular resolution. Preprint at bioRxiv https://doi.org/10.1101/2020.03.12.989806 (2020).

  35. Luecken, M. D. & Theis, F. J. Current best practices in single-cell RNA-seq analysis: a tutorial. Mol. Syst. Biol. 15, e8746 (2019).

    Article  PubMed  PubMed Central  Google Scholar 

  36. Espina, V. et al. Laser-capture microdissection. Nat. Protoc. 1, 586–603 (2006).

    Article  CAS  PubMed  Google Scholar 

  37. Combs, P. A. & Eisen, M. B. Sequencing mRNA from cryo-sliced Drosophila embryos to determine genome-wide spatial patterns of gene expression. PLoS ONE 8, e71820 (2013).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  38. Junker, J. P. et al. Genome-wide RNA tomography in the zebrafish embryo. Cell 159, 662–675 (2014).

    Article  CAS  PubMed  Google Scholar 

  39. Mémoli, F. On the use of Gromov-Hausdorff distances for shape comparison. in Eurographics Symposium on Point Based Graphics (eds Botsch, M. et al) https://doi.org/10.2312/SPBG/SPBG07/081-090 (2007).

  40. Peyre, G., Cuturi, M. & Solomon, J. Gromov-Wasserstein averaging of kernel and distance matrices. in Proceedings of the 33rd International Conference on International Conference on Machine Learning https://dspace.mit.edu/handle/1721.1/112918 (2016).

  41. Halpern, K. B. et al. Single-cell spatial reconstruction reveals global division of labour in the mammalian liver. Nature 542, 352–356 (2017).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  42. Waldhaus, J., Durruthy-Durruthy, R. & Heller, S. Quantitative high-resolution cellular map of the organ of corti. Cell Rep. 11, 1385–1399 (2015).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  43. Habib, N. et al. Div-Seq: single-nucleus RNA-seq reveals dynamics of rare adult newborn neurons. Science 353, 925–928 (2016).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  44. Ren, X. et al. Reconstruction of cell spatial organization from single-cell RNA sequencing data based on ligand-receptor mediated self-assembly. Cell Res. 30, 763–778 (2020).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  45. Cang, Z. & Nie, Q. Inferring spatial and signaling relationships between cells from single cell transcriptomic data. Nat. Commun. 11, 2084 (2020).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  46. Larkin, A. et al. FlyBase: updates to the Drosophila melanogaster knowledge base. Nucleic Acids Res. 49, D899–D907 (2021).

    Article  CAS  PubMed  Google Scholar 

  47. Park, J. et al. Single-cell transcriptomics of the mouse kidney reveals potential cellular targets of kidney disease. Science 360, 758–763 (2018).

    Article  CAS  PubMed  PubMed Central  Google Scholar 

  48. Wolf, F. A., Angerer, P. & Theis, F. J. SCANPY: large-scale single-cell gene expression data analysis. Genome Biol. 19, 15 (2018).

    Article  PubMed  PubMed Central  Google Scholar 

  49. Moriel, N. et al. NovoSpaRc: flexible spatial reconstruction of single-cell gene expression with optimal transport. Zenodo https://doi.org/10.5281/zenodo.4661199 (2021).

Download references

Acknowledgements

N.M. is supported by the Center for Interdisciplinary Data Science Research at the Hebrew University of Jerusalem. N.K. and E.S were supported by the DFG grant KA 5006/1-1. M.N. is supported by an Early Career Faculty Fellowship by the Azrieli Foundation. N.F. is supported in part by Israel Science Foundation grants 1064/19 and 2612/18 and an Alexander von Humboldt Foundation Research award.

Author information

Authors and Affiliations

Authors

Contributions

This protocol is based on a paper by M.N., N.K., N.F. and N.R. Here, N.M., E.S., N.K. and M.N. implemented the method and performed computational and data analyses. N.M., E.S., N.F., N.R., N.K. and M.N. wrote the manuscript.

Corresponding authors

Correspondence to Nikos Karaiskos or Mor Nitzan.

Ethics declarations

Competing interests

The authors declare no competing interests.

Additional information

Peer review information Nature Protocols thanks Jean Yee Hwa Yang and the other, anonymous reviewer(s) for their contribution to the peer review of this work.

Publisher’s note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Related links

Key references using this protocol

Nitzan, M. et al. Nature 576, 132–137 (2019): https://doi.org/10.1038/s41586-019-1773-3

Key data used in this protocol

Waldhaus, J. et al. Cell Rep. 11, 1385–1399 (2015): https://doi.org/10.1016/j.celrep.2015.04.062

Xia, C. et al. Proc. Natl Acad. Sci. USA 116, 19490–19499 (2019): https://doi.org/10.1073/pnas.1912459116

Park, J. et al. Science 360, 758–763 (2018): https://doi.org/10.1126/science.aar2131

Karaiskos, N. et al. Science 358, 194–199 (2017): https://doi.org/10.1126/science.aan3235

Larkin, A. et al. Nucleic Acids Res. 49, D899–D907 (2021): https://doi.org/10.1093/nar/gkaa1026

Rights and permissions

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Moriel, N., Senel, E., Friedman, N. et al. NovoSpaRc: flexible spatial reconstruction of single-cell gene expression with optimal transport. Nat Protoc 16, 4177–4200 (2021). https://doi.org/10.1038/s41596-021-00573-7

Download citation

  • Received:

  • Accepted:

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1038/s41596-021-00573-7

This article is cited by

Comments

By submitting a comment you agree to abide by our Terms and Community Guidelines. If you find something abusive or that does not comply with our terms or guidelines please flag it as inappropriate.

Search

Quick links

Nature Briefing AI and Robotics

Sign up for the Nature Briefing: AI and Robotics newsletter — what matters in AI and robotics research, free to your inbox weekly.

Get the most important science stories of the day, free in your inbox. Sign up for Nature Briefing: AI and Robotics