Anndata
Handles annotated matrices in single-cell analysis, .h5ad and Zarr files, and...
Install
npx skills add K-Dense-AI/scientific-agent-skills --skill anndata -g -a claude-code -y- Repository
- K-Dense-AI/scientific-agent-skills55.7k
- Category
- Engineering
- Updated
- 9d ago
- License
- BSD-3-Clause license
- Context cost
- Mediumabout 3,000 tokens
- Runs scripts
- No, instructions only
What it does
Handles annotated matrices in single-cell analysis, .h5ad and Zarr files, and integration with the scverse ecosystem. This is the data format skill, for analysis workflows use scanpy; for probabilistic models use scvi-tools; for population-scale queries use cellxgene-census.
AnnData
Overview
AnnData is a Python package for handling annotated data matrices, storing experimental measurements (X) alongside observation metadata (obs), variable metadata (var), and multi-dimensional annotations (obsm, varm, obsp, varp, uns). Originally designed for single-cell genomics through Scanpy, it now serves as a general-purpose framework for any annotated data requiring efficient storage, manipulation, and analysis.
When to Use This Skill
Use this skill when:
- Creating, reading, or writing AnnData objects
- Working with h5ad, zarr, or other genomics data formats
- Performing single-cell RNA-seq analysis
- Managing large datasets with sparse matrices or backed mode
- Concatenating multiple datasets or experimental batches
- Subsetting, filtering, or transforming annotated data
- Integrating with scanpy, scvi-tools, or other scverse ecosystem tools
Installation
Targets AnnData 0.13.4 (current PyPI release reviewed 2026-09-30), requiring Python 3.12+. Small synthetic checks cover dense/sparse matrices, native I/O, metadata, concatenation, and lazy reads. File paths, biological analysis, remote stores, and third-party integration examples are illustrative unless stated otherwise.
uv pip install "anndata==0.13.4"
# Lazy I/O and dask-backed operations
uv pip install "anndata[dask,lazy]==0.13.4"
Use unpinned installs only when intentionally tracking the latest compatible release.
