anndata

Load, save, subset, concatenate, and restructure AnnData objects across h5ad and zarr formats.

Updated Jul 1, 2026
One-click install
npx skills add https://github.com/jasrajtulsi/GRAD-SCOPE --skill anndata-jasrajtulsi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: anndata
Source: https://github.com/jasrajtulsi/GRAD-SCOPE/tree/main/.claude/skills/anndata
Command: npx skills add https://github.com/jasrajtulsi/GRAD-SCOPE --skill anndata-jasrajtulsi

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill removes the friction of working with annotated matrices in single-cell and other high-dimensional analysis workflows. It helps you read, write, structure, subset, and combine AnnData objects while keeping observations, variables, layers, embeddings, and metadata aligned.

Core Features & Use Cases

  • Data structure management: Create and inspect AnnData objects with X, obs, var, layers, obsm, varm, obsp, varp, uns, and raw.
  • I/O and interoperability: Load and save h5ad, zarr, csv, mtx, loom, Excel, and other supported formats for robust data exchange.
  • Concatenation and manipulation: Merge batches, reorder or filter cells and genes, and preserve metadata integrity during subsetting or transformation.
  • Best-practice workflows: Use backed mode, sparse matrices, categoricals, and chunked processing to handle large datasets efficiently.
  • Use case: A researcher can load multiple single-cell batches, merge them into one AnnData object, filter low-quality cells, and save the processed result for Scanpy or scverse tools.

Quick Start

Use the anndata skill to help me load a .h5ad file, inspect its metadata, and suggest the safest way to subset and save it for downstream single-cell analysis.

Frequently Asked Questions about anndata

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I load and inspect a single-cell h5ad file for downstream analysis?

To load and inspect a single-cell h5ad file, read the AnnData object into memory and access its X matrix alongside obs and var metadata. This ensures observations and variables remain aligned for immediate scverse or Scanpy workflows.

What is the best way to concatenate multiple single-cell batches into one AnnData object?

Concatenating multiple single-cell batches involves merging AnnData objects while preserving observations, variables, and layers. You can combine batches and maintain metadata integrity across obs and var to ensure seamless downstream analysis.

Can I use backed mode and sparse matrices for memory-efficient AnnData processing?

Yes, backed mode and sparse matrices enable memory-efficient AnnData processing for large datasets. These best-practice workflows allow chunked processing and categorical handling without loading entire high-dimensional matrices into memory.

Does AnnData support saving and loading zarr formats for high-dimensional data?

AnnData supports saving and loading zarr formats alongside h5ad, csv, mtx, and loom for robust data exchange. This I/O interoperability allows you to structure and save annotated matrices for scverse-compatible preparation.

How do I subset and filter cells or genes while preserving AnnData metadata alignment?

Subsetting and filtering cells or genes preserves AnnData metadata alignment by automatically adjusting obs, var, layers, and embeddings simultaneously. This restructuring maintains metadata integrity during transformations without manual index correction.