Skip to content

Commit c5e9681

Browse files
[pre-commit.ci] pre-commit autoupdate (#1158)
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/rbubley/mirrors-prettier: v3.8.4 → v3.9.4](rbubley/mirrors-prettier@v3.8.4...v3.9.4) - [github.com/astral-sh/ruff-pre-commit: v0.15.18 → v0.15.20](astral-sh/ruff-pre-commit@v0.15.18...v0.15.20) * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 832f4b2 commit c5e9681

2 files changed

Lines changed: 32 additions & 34 deletions

File tree

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ ci:
99
skip: []
1010
repos:
1111
- repo: https://github.com/rbubley/mirrors-prettier
12-
rev: v3.8.4
12+
rev: v3.9.4
1313
hooks:
1414
- id: prettier
1515
exclude: ^.github/workflows/test.yaml
@@ -20,7 +20,7 @@ repos:
2020
additional_dependencies: [numpy, types-requests]
2121
exclude: tests/|docs/
2222
- repo: https://github.com/astral-sh/ruff-pre-commit
23-
rev: v0.15.18
23+
rev: v0.15.20
2424
hooks:
2525
- id: ruff
2626
args: [--fix, --exit-non-zero-on-fix]

docs/user_guide.md

Lines changed: 30 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ Please see [this section](https://spatialdata.scverse.org/en/stable/tutorials/no
3737

3838
<details open>
3939
<summary><h3>If you have an existing Squidpy object.</summary>
40-
40+
4141
Please have a look at [this tutorial](https://github.com/scverse/spatialdata-notebooks/blob/main/notebooks%2Fexamples%2Fsdata_from_scratch.ipynb).
42-
42+
4343
</details>
44-
44+
4545
<details open>
4646
<summary><h3>If you want to start from raw files</summary>
47-
47+
4848
If you don’t have a SpatialData object or corresponding zarr file, you will have to create a SpatialData object to make use of the SpatialData framework.
49-
You can create a SpatialData object directly from your raw files (e.g. CSVs, cell-gene matrix/cell-proteins matrix, images etc.) by using the [spatialdata-io](https://github.com/scverse/spatialdata-io) library that has reader functions for most spatial omics techniques. See [here](https://spatialdata.scverse.org/projects/io/en/latest/) for a list of currently supported technologies.
50-
49+
You can create a SpatialData object directly from your raw files (e.g. CSVs, cell-gene matrix/cell-proteins matrix, images etc.) by using the [spatialdata-io](https://github.com/scverse/spatialdata-io) library that has reader functions for most spatial omics techniques. See [here](https://spatialdata.scverse.org/projects/io/en/latest/) for a list of currently supported technologies.
50+
5151
For example, if you have data coming from a MERSCOPE®, just use:
5252

5353
```
@@ -61,12 +61,12 @@ Please also see [this section](https://spatialdata.scverse.org/en/stable/tutoria
6161
If there is no reader implemented for your data type, please refer to [this section](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/models1.html#construct-a-spatialdata-object-from-scratch) to learn about building SpatialData objects from scratch.
6262

6363
</details>
64-
64+
6565
<details open>
6666
<summary><h3>If you want to play around with existing data.</summary>
67-
67+
6868
Please see [here](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/datasets/README.html) for a repository of demo datasets (already available as .zarr) generated with different spatial omics technologies.
69-
69+
7070
</details>
7171
</details>
7272

@@ -92,41 +92,40 @@ Yes → Check out our [Transformation/coordinate system tutorial](https://spatia
9292
</details>
9393

9494
<details open>
95-
<summary><h2>How do I annotate my data?</summary>
96-
97-
Annotation can have a lot of meanings. You might want to annotate specific regions in your tissue as tumor, add more details about your cell shapes, group together specific transcripts, include celltype annotations or cell sizes for your cells etc.
95+
<summary><h2>How do I annotate my data?</summary>
96+
97+
Annotation can have a lot of meanings. You might want to annotate specific regions in your tissue as tumor, add more details about your cell shapes, group together specific transcripts, include celltype annotations or cell sizes for your cells etc.
9898
<details open>
9999
<summary> <h3> How can I spatially annotate regions in my data? </summary>
100-
100+
101101
This is possible within the SpatialData framework, making use of napari, like explained [in this tutorial](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/napari_rois.html).
102102

103103
</details>
104104
<details open>
105105
<summary> <h3> I have annotated regions in an external tool, how do I add them to SpatialData?</summary>
106-
107-
If the annotated regions are saved in a geojson, you can add them as follows:
108-
```
106+
107+
If the annotated regions are saved in a geojson, you can add them as follows:
108+
109+
```
109110
from spatialdata.models import ShapesModel
110111
sdata['very_interesting_regions']=ShapesModel.parse('path_to_geojson')
111112
```
113+
112114
For more details, including information on how to add annotations for these regions, please have a look at [this tutorial](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/tables.html).
113115

114116
</details>
115-
117+
116118
<details open>
117-
118-
119+
119120
<summary> <h3> I have cells in my dataset, how do I annotate them? (usage of AnnData)</summary>
120121

121122
One of the most obvious things to do for spatial omics data is to annotate cells using the [AnnData](https://anndata.readthedocs.io/en/stable/) format (called tables in SpatialData). These tables can contain count/intensity data, all types of annotations, and make it possible to make use of [scanpy](https://scanpy.readthedocs.io/en/stable/) functionality (normalization/clustering/DE calculation).
122123
If you want more technical details on how to create a table from scratch to annotate your shapes/labels/points, you can have a look [here](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/models2.html#tables).
123124

124125
</details>
125-
126-
127-
126+
128127
</details>
129-
128+
130129
<details open>
131130
<summary><h2>How do I analyze a spatial subset of my data?
132131
</summary>
@@ -136,20 +135,19 @@ Therefore, subsampling your data based on spatial coordinates can be helpful. Ot
136135

137136
<details open>
138137
<summary><h3>I want to annotate a specific region myself.</summary>
139-
138+
140139
Please see the previous section ('How do I annotate my data?') and then specifically the section about spatially annotating regions. This will guide you through the process of extracting coordinates, which will be used for spatially subsetting the data. Next, see below.
141140
</details>
142141

143142
<details open>
144143
<summary><h3>I know the coordinates of the region I want to subsample.</summary>
145-
144+
146145
You will need to perform a spatial query, which filters the data based on spatial coordinates. Please see [this tutorial](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/spatial_query.html).
147-
146+
148147
</details>
149148

150149
</details>
151-
152-
150+
153151
<details open>
154152
<summary><h2>How do I visualize my data?</summary>
155153

@@ -191,9 +189,9 @@ The method of aggregation depends on the type of elements in your SpatialData ob
191189

192190
</details>
193191
<details open>
194-
192+
195193
<summary> <h2> SpatialData looks amazing, I want to learn more. Give me all the technical details!</summary>
196-
194+
197195
Sure, no problem! There is much more to learn about SpatialData.
198196

199197
You want to learn how to combine SpatialData and deep learning? We got you covered [here](https://spatialdata.scverse.org/en/stable/tutorials/notebooks/notebooks/examples/densenet.html).
@@ -203,9 +201,9 @@ If you want to create a labels layer from your shapes (rasterize), a shapes laye
203201
Finally here is a more [advanced technical tutorial on transformations](https://spatialdata.scverse.org/en/latest/tutorials/notebooks/notebooks/examples/transformations_advanced.html#other-technical-topics).
204202

205203
</details>
206-
204+
207205
<details open>
208-
206+
209207
<summary> <h2> I am sold, how can I get in touch and contribute to SpatialData?
210208

211209
</summary>

0 commit comments

Comments
 (0)