Spatial Transcriptomics Visium Analysis

An analysis workflow for 10x Visium spatial transcriptomics, which measures gene activity at locations across a tissue section.

In plain words
What is it for?
Use it with Space Ranger, H5AD, or H5 data to find spatially variable genes, cluster tissue domains, and study neighborhoods and cell-type co-occurrence.
Why use it?
It connects gene activity with tissue position, helping distinguish tissue regions and genes whose activity varies across the section.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/tiangzlab/omicsclaw/spatial-transcriptomics
Any agent
npx skills add TianGzlab/OmicsClaw --skill spatial-transcriptomics
Clone the repo
git clone --depth 1 https://github.com/TianGzlab/OmicsClaw

Made for: Claude Code, Codex.

Per session 6 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,204 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00006 $0.03204
Opus 5 $0.00003 $0.01602
Sonnet 5 $0.00001 $0.00641
Haiku 4.5 $0.00001 $0.00320

Measured 2d ago against content hash 548fe8b3c528, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

Spatial Transcriptomics Visium Analysis scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

The scan reads SKILL.md. This mod also ships 4 executable files (scripts/export_results.py, scripts/generate_all_plots.py, scripts/load_example_data.py, …), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

knowledge_base/spatial-transcriptomics/SKILL.md · 257 lines

How it starts

The opening of the file, as written. The whole thing — 257 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Spatial Transcriptomics Visium Analysis

When to Use This Skill

  • You have 10x Visium spatial gene expression data (with or without H&E image)
  • You want to identify spatially variable genes across a tissue section
  • You want to discover spatial tissue domains via clustering
  • You want to quantify neighborhood enrichment between cell clusters
  • You want to analyze co-occurrence patterns of cell types across distances
  • Input is Space Ranger output, .h5ad, or .h5 file

Not for: Single-molecule FISH (MERFISH/Xenium), Slide-seq, or single-cell RNA-seq without spatial coordinates. For scRNA-seq, use scrnaseq-scanpy-core-analysis.

Installation

pip install squidpy scanpy anndata scikit-misc plotnine plotnine-prism seaborn matplotlib numpy pandas scikit-learn
Package Version License Commercial Use Installation
squidpy ≥1.4 BSD-3-Clause ✅ Permitted pip install squidpy
scanpy ≥1.9 BSD-3-Clause ✅ Permitted pip install scanpy
anndata ≥0.8 BSD-3-Clause ✅ Permitted pip install anndata
plotnine ≥0.12 MIT ✅ Permitted pip install plotnine
plotnine-prism ≥0.2 MIT ✅ Permitted pip install plotnine-prism
seaborn ≥0.11 BSD-3-Clause ✅ Permitted pip install seaborn
matplotlib ≥3.5 PSF ✅ Permitted pip install matplotlib
scikit-learn ≥1.0 BSD-3-Clause ✅ Permitted pip install scikit-learn
scikit-misc ≥0.1 BSD-3-Clause ✅ Permitted pip install scikit-misc
numpy ≥1.21 BSD-3-Clause ✅ Permitted pip install numpy
pandas ≥1.3 BSD-3-Clause ✅ Permitted pip install pandas

License Compliance: All packages use permissive licenses (BSD, MIT, PSF) that permit commercial use in AI agent applications.

Inputs

Input Format Description
Visium data .h5ad, .h5, or Space Ranger directory Gene expression + spatial coordinates
H&E image Embedded in above Tissue histology (optional, enhances spatial plots)

Read the full file on GitHub · 257 lines

Files

What ships with it

5 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 257 lines · 6 tokens per session scan A 548fe8b3c528

Subscribe to this mod's changes

Spatial Transcriptomics Visium Analysis is a skill published in the GitHub repository TianGzlab/OmicsClaw (159 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 6 tokens to every session and 3,204 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

cellxgene-census-query

Query CZ CELLxGENE Census (61M+ cells). Filter by cell type/tissue/disease, retrieve expression data, and integrate with scanpy/PyTorch for population-scale single-cell analysis. Use this skill when: (1) Querying single-cell expression data by cell type, tissue, or disease, (2) Exploring available single-cell datasets…

PharMolix/OpenBioMed · 105 tokens

single-cell-scrna-seq-analysis-scanpy

Complete single-cell RNA-seq analysis workflow built on Scanpy and AnnData. Use this skill when: (1) Loading diverse single-cell data formats (10X, h5ad, CSV), (2) Performing quality control and filtering, (3) Normalization, dimensionality reduction, and clustering, (4) Marker gene identification and cell type…

PharMolix/OpenBioMed · 85 tokens

single-cell-multi-omics-analysis-scvi

Probabilistic deep learning framework for single-cell multi-omics data analysis. Use this skill when: (1) Analyzing single-cell RNA-seq data with batch correction, (2) Integrating multi-modal data (CITE-seq, ATAC-seq, multi-omics), (3) Performing cell type annotation with scANVI, (4) Spatial transcriptomics…

PharMolix/OpenBioMed · 94 tokens

decoupler

Use for any task involving the decoupler library — inferring biological activity/enrichment scores from omics data (bulk, single-cell, spatial). Triggers on estimating transcription factor (TF) activity, pathway activity, or gene-set enrichment from an AnnData/DataFrame; running ulm, mlm, ora, gsea, gsva, aucell…

scverse/decoupler · 220 tokens

cell-composition

Determine cell type composition at each spatial location through deconvolution or annotation. Use when user wants to know what cell types exist, their proportions, or where specific cells are located. Triggers: "cell type composition", "deconvolution", "what cells are here", "cell type proportions", "estimate cell…

cafferychen777/ChatSpatial · 78 tokens

differential-analysis

Find differentially expressed genes between conditions, regions, or cell types. Use when user wants to compare gene expression, find markers, or identify condition-specific changes. Triggers: "differential expression", "DEG", "marker genes", "compare conditions", "what genes differ", "find markers", "condition…

cafferychen777/ChatSpatial · 74 tokens