You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/source/getting_started.rst
+6-1
Original file line number
Diff line number
Diff line change
@@ -17,8 +17,13 @@ Cell Level
17
17
**************************
18
18
To install Tangram, make sure you have `PyTorch <https://pytorch.org/>`_ and `scanpy <https://scanpy.readthedocs.io/en/stable/>`_ installed. If you need more details on the dependences, look at the `environment.yml <https://github.com/broadinstitute/Tangram/blob/master/environment.yml>`_ file.
Copy file name to clipboardExpand all lines: docs/source/news.rst
+1-1
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,6 @@ Tangram News
5
5
6
6
- On Mar 9th 2021, Nicholas Eagles wrote a `blog post <http://research.libd.org/rstatsclub/2021/03/09/lessons-learned-applying-tangram-on-visium-data/#.YPsZphNKhb->`_ about applying Tangram on Visium data.
7
7
8
-
- The Tangram method has been used by our colleagues at Harvard and Broad Institute, to map cell types for the developmental mouse brain -see Fig. 2 [`Nature(2021)<https://www.nature.com/articles/s41586-021-03670-5>`_]
8
+
- The Tangram method has been used by our colleagues at Harvard and Broad Institute, to map cell types for the developmental mouse brain -see Fig. 2 (`Nature(2021)<https://www.nature.com/articles/s41586-021-03670-5>`_ )
9
9
10
10
- Tangram is now officially a part of `Squidpy <https://squidpy.readthedocs.io/en/stable/index.html>`_
A DataFrame with a column for each unique value in the sequence and a one-hot-encoding, and an additional
118
-
column with the input list if 'keep_aggregate' is True.
119
-
The number of rows are equal to len(l).
118
+
column with the input list if 'keep_aggregate' is True.
119
+
The number of rows are equal to len(l).
120
120
"""
121
121
df_enriched=pd.DataFrame({"cl": l})
122
122
foriinl.unique():
@@ -137,7 +137,7 @@ def project_cell_annotations(
137
137
adata_sp (AnnData): spatial data used to save the mapping result.
138
138
annotation (str): Optional. Cell annotations matrix with shape (number_cells, number_annotations). Default is 'cell_type'.
139
139
threshold (float): Optional. Valid for using with adata_map.obs['F_out'] from 'constrained' mode mapping.
140
-
Cell's probability below this threshold will be dropped. Default is 0.5.
140
+
Cell's probability below this threshold will be dropped. Default is 0.5.
141
141
Returns:
142
142
None.
143
143
Update spatial Anndata by creating `obsm` `tangram_ct_pred` field with a dataframe with spatial prediction for each annotation (number_spots, number_annotations)
Copy file name to clipboardExpand all lines: tutorial_sq_tangram.ipynb
+12-5
Original file line number
Diff line number
Diff line change
@@ -515,14 +515,15 @@
515
515
"cell_type": "markdown",
516
516
"metadata": {},
517
517
"source": [
518
-
"***\n",
519
-
"## The _Tangram_ trick: scRNA-seq are the new spatial data\n",
518
+
"****\n",
519
+
"\n",
520
+
"### The _Tangram_ trick: scRNA-seq are the new spatial data\n",
520
521
"\n",
521
522
"_Tangram_ learns a spatial alignment of the single cell data by looking at a subset of genes, specified by the user, called the training genes. Training genes need to bear interesting signal and to be measured with high quality. Typically, we choose the training genes are 100-1000 differentially expressedx genes, stratified across cell types. Sometimes, we also use the entire transcriptome, or perform different mappings using different set of training genes to see how much the result change.\n",
522
523
"\n",
523
524
"_Tangram_ fits the scRNA-seq profiles on space using a custom loss function based on cosine similarity. The method is summarized in the sketch below:\n",
524
525
"\n",
525
-
""
526
+
"\n"
526
527
]
527
528
},
528
529
{
@@ -1445,8 +1446,14 @@
1445
1446
"cell_type": "markdown",
1446
1447
"metadata": {},
1447
1448
"source": [
1448
-
"***\n",
1449
-
"## Deconvolution\n",
1449
+
"***"
1450
+
]
1451
+
},
1452
+
{
1453
+
"cell_type": "markdown",
1454
+
"metadata": {},
1455
+
"source": [
1456
+
"### Deconvolution\n",
1450
1457
"\n",
1451
1458
"For untargeted spatial technologies, like Visium and Slide-seq, a spatial voxel may contain more than one cells. In these cases, it might be useful to disentangle gene expression into single cells - a process called deconvolution. Deconvolution is a requested feature, and also hard to obtain accurately with computational methods. If your goal is to study co-localization of cell types, we recommend you work with the spatial cell type maps instead. If your aim is discovery of cell-cell communication mechanisms, we suggest you compute gene programs, then use `project_cell_annotations` to spatially visualize program usage. To proceed with deconvolution anyways, see below.\n",
0 commit comments