anndata — Claude Code skill: annotated matrices for single-cell data
Skill to create, read, and transform annotated data matrices in h5ad and Zarr formats. Integrates with the scverse ecosystem for transcriptomics and other metadata-rich data analysis.
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a claude-codeWhat anndata does
anndata stores experimental measurements (matrix X) with observation metadata, variable metadata, and multi-dimensional annotations. You can work with sparse matrices, use backed mode for large files, combine multiple datasets, and filter data by conditions.
The skill supports native h5ad and zarr formats, plus reads CSV, MTX, Loom, and 10X Genomics (via scanpy). Lazy I/O and dask operations require optional packages. Remote storage access needs internet and provider-specific fsspec adapters.
Requires Python 3.12+ and anndata 0.13.4; install via uv. Version 0.13 changes the API: use ad.concat instead of concatenate(), import readers from anndata.io, check layer names against None during iteration. Backed sparse matrices no longer support direct assignment.
What it helps with
- read and write annotated matrices in h5ad and zarr formats
- filter and subset data by cell or gene metadata
- combine multiple samples or experiments into one object
- handle large datasets in backed mode without loading into memory
- convert between formats: CSV, MTX, Loom, 10X
Example prompts for the agent
- Create an AnnData object from a matrix of 100 cells by 2000 genes with cell_type and sample metadata
- Read data.h5ad in backed mode, extract the first 100 cells, and save to memory
- Merge three datasets along observations using ad.concat, tracking the source in obs['batch']
How to install anndata
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a claude-code2Manually: put the files in place
~/.claude/skills/anndata/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/anndata/
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a codex2Manually: put the files in place
.agents/skills/anndata/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a cursor2Manually: put the files in place
.cursor/skills/anndata/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install K-Dense-AI/scientific-agent-skills anndata2Manually: put the files in place
.github/skills/anndata/SKILL.md1Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a gemini-cli2Platform CLI
gemini skills install https://github.com/K-Dense-AI/scientific-agent-skills --path skills/anndataManually: put the files in place
.devin/skills/anndata/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
From the same set120
The whole set →Similar
Questions about anndata
How do I install anndata in Claude Code?
Run npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -a claude-code. The skill will be available at ~/.claude/skills/anndata/SKILL.md.
What does anndata do?
It manages matrices where rows are cells or samples, columns are genes or measurements, and metadata is stored separately. It handles efficient storage, fast filtering, and merging of large datasets.
What Python version and dependencies are required?
Requires Python 3.12+ and anndata 0.13.4. For lazy I/O, install extras: uv pip install "anndata[dask,lazy]==0.13.4". Remote storage access needs the appropriate fsspec adapter for your provider.