Skip to content

Commit 110543c

Browse files
committed
update heading anchors in tutorial
1 parent 7b72e41 commit 110543c

1 file changed

Lines changed: 22 additions & 22 deletions

File tree

docs/notebooks/cell2location_tutorial.ipynb

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -39,24 +39,24 @@
3939
"\n",
4040
"\n",
4141
"## Contents\n",
42-
"* [Loading packages](#Loading_packages)\n",
43-
"* [Loading Visium and single cell data data](#Loading_Visium)\n",
44-
"1. [Estimating cell type signatures (NB regression)](#Estimating_signatures)\n",
45-
"2. [Cell2location: spatial mapping](#cell2location)\n",
46-
"3. [Visualising cell abundance in spatial coordinates](#Visualising)\n",
47-
"4. [Downstream analysis](#downstream)\n",
48-
"* [Leiden clustering of cell abundance](#region_clustering)\n",
49-
"* [Identifying cellular compartments / tissue zones using matrix factorisation (NMF)](#NMF)\n",
50-
"5. [Advanced use](#advanced)\n",
51-
"* [Estimate cell-type specific expression of every gene in the spatial data](#per_cell_type_expression)\n",
52-
"* [Working with the posterior distribution and computing arbitrary quantiles](#posterior_summary)"
42+
"* [Loading packages](#Loading-packages)\n",
43+
"* [Loading Visium and single cell data data](#Loading-Visium-and-scRNA-seq-reference-data)\n",
44+
"1. [Estimating cell type signatures (NB regression)](#Estimation-of-reference-cell-type-signatures-(NB-regression))\n",
45+
"2. [Cell2location: spatial mapping](#Cell2location:-spatial-mapping)\n",
46+
"3. [Visualising cell abundance in spatial coordinates](#Visualising-cell-abundance-in-spatial-coordinates)\n",
47+
"4. [Downstream analysis](#Downstream-analysis)\n",
48+
"* [Leiden clustering of cell abundance](#Identifying-discrete-tissue-regions-by-Leiden-clustering)\n",
49+
"* [Identifying cellular compartments / tissue zones using matrix factorisation (NMF)](#Identifying-cellular-compartments-/-tissue-zones-using-matrix-factorisation-(NMF))\n",
50+
"* [Estimate cell-type specific expression of every gene in the spatial data (needed for NCEM)](#Estimate-cell-type-specific-expression-of-every-gene-in-the-spatial-data-(needed-for-NCEM))\n",
51+
"5. [Advanced use](#Advanced-use)\n",
52+
"* [Working with the posterior distribution and computing arbitrary quantiles](#Working-with-the-posterior-distribution-and-computing-arbitrary-quantiles)"
5353
]
5454
},
5555
{
5656
"cell_type": "markdown",
5757
"metadata": {},
5858
"source": [
59-
"## Loading packages <a class=\"anchor\" id=\"Loading_packages\"></a>"
59+
"## Loading packages <a class=\"anchor\" id=\"Loading-packages\"></a>"
6060
]
6161
},
6262
{
@@ -126,7 +126,7 @@
126126
"cell_type": "markdown",
127127
"metadata": {},
128128
"source": [
129-
"## Loading Visium and scRNA-seq reference data <a class=\"anchor\" id=\"Loading_Visium\"></a>"
129+
"## Loading Visium and scRNA-seq reference data <a class=\"anchor\" id=\"Loading-Visium-and-scRNA-seq-reference-data\"></a>"
130130
]
131131
},
132132
{
@@ -300,7 +300,7 @@
300300
"cell_type": "markdown",
301301
"metadata": {},
302302
"source": [
303-
"## Estimation of reference cell type signatures (NB regression) <a class=\"anchor\" id=\"Estimating_signatures\"></a>\n",
303+
"## Estimation of reference cell type signatures (NB regression) <a class=\"anchor\" id=\"Estimation-of-reference-cell-type-signatures-(NB-regression)\"></a>\n",
304304
"\n",
305305
"The signatures are estimated from scRNA-seq data, accounting for batch effect, using a Negative binomial regression model.\n",
306306
"\n",
@@ -990,7 +990,7 @@
990990
"cell_type": "markdown",
991991
"metadata": {},
992992
"source": [
993-
"## Cell2location: spatial mapping <a class=\"anchor\" id=\"cell2location\"></a>\n",
993+
"## Cell2location: spatial mapping <a class=\"anchor\" id=\"Cell2location:-spatial-mapping\"></a>\n",
994994
"\n",
995995
"<div class=\"alert alert-block alert-message\">\n",
996996
"<b>Find shared genes and prepare anndata.</b>\n",
@@ -1418,7 +1418,7 @@
14181418
"cell_type": "markdown",
14191419
"metadata": {},
14201420
"source": [
1421-
"## Visualising cell abundance in spatial coordinates <a class=\"anchor\" id=\"Visualising\"></a>\n",
1421+
"## Visualising cell abundance in spatial coordinates <a class=\"anchor\" id=\"Visualising-cell-abundance-in-spatial-coordinates\"></a>\n",
14221422
"\n",
14231423
"<div class=\"alert alert-info\">\n",
14241424
"Note\n",
@@ -1517,9 +1517,9 @@
15171517
"cell_type": "markdown",
15181518
"metadata": {},
15191519
"source": [
1520-
"## Downstream analysis <a class=\"anchor\" id=\"downstream\"></a>\n",
1520+
"## Downstream analysis <a class=\"anchor\" id=\"Downstream-analysis\"></a>\n",
15211521
"\n",
1522-
"### Identifying discrete tissue regions by Leiden clustering<a class=\"anchor\" id=\"region_clustering\"></a>\n",
1522+
"### Identifying discrete tissue regions by Leiden clustering<a class=\"anchor\" id=\"Identifying-discrete-tissue-regions-by-Leiden-clustering\"></a>\n",
15231523
"\n",
15241524
"We identify tissue regions that differ in their cell composition by clustering locations using cell abundance estimated by cell2location. \n",
15251525
"\n",
@@ -1623,7 +1623,7 @@
16231623
"cell_type": "markdown",
16241624
"metadata": {},
16251625
"source": [
1626-
"### Identifying cellular compartments / tissue zones using matrix factorisation (NMF) <a name=\"NMF\"></a>\n",
1626+
"### Identifying cellular compartments / tissue zones using matrix factorisation (NMF) <a name=\"Identifying-cellular-compartments-/-tissue-zones-using-matrix-factorisation-(NMF)\"></a>\n",
16271627
"\n",
16281628
"Here, we use the cell2location mapping results to identify the spatial co-occurrence of cell types in order to better understand the tissue organisation and predict cellular interactions. We performed non-negative matrix factorization (NMF) of the cell type abundance estimates from cell2location ([paper section 4, Fig 4D](https://www.nature.com/articles/s41587-021-01139-4)). Similar to the established benefits of applying NMF to conventional scRNA-seq, the additive NMF decomposition yielded a grouping of spatial cell type abundance profiles into components that capture co-localised cell types ([Supplemenary Methods section 4.2, p. 60](https://www.nature.com/articles/s41587-021-01139-4#Sec50)). This NMF-based decomposition naturally accounts for the fact that multiple cell types and microenvironments can co-exist at the same Visium locations (see [paper Fig S20, p. 34](https://www.nature.com/articles/s41587-021-01139-4#Sec50)), while sharing information across tissue areas (e.g. individual germinal centres). \n",
16291629
"\n",
@@ -1762,7 +1762,7 @@
17621762
"cell_type": "markdown",
17631763
"metadata": {},
17641764
"source": [
1765-
"### Estimate cell-type specific expression of every gene in the spatial data (needed for NCEM) <a name=\"per_cell_type_expression\"></a>\n",
1765+
"### Estimate cell-type specific expression of every gene in the spatial data (needed for NCEM) <a name=\"Estimate-cell-type-specific-expression-of-every-gene-in-the-spatial-data-(needed-for-NCEM)\"></a>\n",
17661766
"\n",
17671767
"The cell-type specific expression of every gene at every spatial location in the spatial data enables learning cell communication with NCEM model using Visium data (https://github.com/theislab/ncem). \n",
17681768
"\n",
@@ -1865,7 +1865,7 @@
18651865
"cell_type": "markdown",
18661866
"metadata": {},
18671867
"source": [
1868-
"### Working with the posterior distribution and computing arbitrary quantiles <a name=\"posterior_summary\"></a>\n",
1868+
"### Working with the posterior distribution and computing arbitrary quantiles <a name=\"Working-with-the-posterior-distribution-and-computing-arbitrary-quantiles\"></a>\n",
18691869
"\n",
18701870
"In addition to the posterior distribution mean, std and quantiles presented earlier in the notebook you can fetch an arbitrary number of samples from the posterior distribution. To limit memory use, it could be beneficial to select particular varibles in the model. \n",
18711871
"\n",
@@ -1943,7 +1943,7 @@
19431943
"cell_type": "markdown",
19441944
"metadata": {},
19451945
"source": [
1946-
"#### Modules and their versions used for this analysis\n",
1946+
"### Modules and their versions used for this analysis\n",
19471947
"\n",
19481948
"\n",
19491949
"Useful for debugging and reporting issues."

0 commit comments

Comments
 (0)