Skip to content

Commit 53d80b6

Browse files
committed
fix docs for scanpy v1.11
1 parent 70d6d5c commit 53d80b6

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

docs/source/usage.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,15 @@ print(f"Spatial resolution: {spatial_resolution:.3f}")
146146

147147
In our case we can compare the resulting clusters to the annotated ground truth regions. If we are not satisfied with the results, we can go back and tweak other parameters such as the underlying neighborhood graphs or the `layer_ratio` to achieve the desired granularity of our results.
148148

149+
```{code-cell} ipython3
150+
---
151+
tags: [hide-cell]
152+
---
153+
154+
# needed for scanpy v1.11 otherwise plotting fails because the number of clusters changed
155+
del adata.uns["spatialleiden_colors"]
156+
```
157+
149158
```{code-cell} ipython3
150159
sc.pl.embedding(adata, basis="spatial", color=["spatialleiden", "Region"])
151160
```

0 commit comments

Comments
 (0)