Standard scRNA-seq preprocessing and clustering with Scanpy. Use for QC, normalization, HVG selection, PCA, neighbor graph construction, UMAP, Leiden clustering, and export of an analysis-ready AnnData object.
npx skills add https://github.com/BioTender-max/awesome-bio-agent-skills --skill scrna-preprocessing-clustering
Reference examples assume:
scanpy 1.10+anndata 0.10+pandas 2.2+matplotlib 3.8+Before using code patterns, verify installed versions match the environment:
python -c "import scanpy, anndata; print(scanpy.__version__, anndata.__version__)"Use this skill to turn raw or minimally processed scRNA-seq data into an analysis-ready object with:
h5ad artifact for annotation, DE, integration, or trajectory analysish5ad inputs need standard preprocessingh5ad, inspect adata.raw, embeddings, cluster columns, and QC columns before rerunning preprocessing.adata.raw = adata.copy() before regression or scaling..pdf or .svg for final figures when possible..h5, .h5ad, or count matrixresults/processed.h5adqc/cell_qc_metrics.tsvqc/gene_qc_metrics.tsvfigures/qc_violin.pdffigures/pca_variance_ratio.pdffigures/umap_leiden.pdfscanpyanndatapandasmatplotlibseabornimport scanpy as sc
adata = sc.read_10x_mtx("counts/")
adata.var_names_make_unique()
adata.var["mt"] = adata.var_names.str.upper().str.startswith("MT-")
sc.pp.calculate_qc_metrics(adata, qc_vars=["mt"], inplace=True)
adata = adata[
(adata.obs["n_genes_by_counts"] >= 200)
& (adata.obs["n_genes_by_counts"] <= 6000)
& (adata.obs["pct_counts_mt"] < 15),
:
].copy()
sc.pp.filter_genes(adata, min_cells=3)
sc.pp.normalize_total(adata, target_sum=1e4)
sc.pp.log1p(adata)
adata.raw = adata.copy()
sc.pp.highly_variable_genes(adata, n_top_genes=3000, flavor="seurat_v3")
adata = adata[:, adata.var["highly_variable"]].copy()
sc.pp.scale(adata, max_value=10)
sc.tl.pca(adata, svd_solver="arpack")
sc.pp.neighbors(adata, n_neighbors=15, n_pcs=30)
sc.tl.umap(adata)
sc.tl.leiden(adata, resolution=0.5, key_added="leiden_r05")
adata.write("results/processed.h5ad")
n_genes_by_countstotal_countspct_counts_mtPlot distributions before filtering. Thresholds vary by chemistry, tissue, and nucleus versus whole-cell assay.
Use dataset-aware thresholds. Good first-pass defaults:
min_genes >= 200max_genes <= 5000-8000 to remove likely doublets in many droplet datasetspct_counts_mt < 10-20 depending on tissue stressmin_cells >= 3 for genestarget_sum=1e4log1p2000-4000 HVGs10-30 PCs and 10-30 neighbors as a starting range0.2, 0.5, 0.8, 1.0Always save:
h5adresults/processed.h5ad: main reusable AnnData objectresults/cluster_assignments.tsv: barcode plus cluster labelsqc/filter_summary.tsv: counts before and after filteringfigures/umap_leiden.pdf: main embedding figureanndatascanpyIntegration with protocols.io API for managing scientific protocols. This skill should be used when working with protocols.io to search, create, update, or publish protocols; manage protocol steps and materials; handle discussions and comments; organize workspaces; upload and manage files; or integrate protocols.io functionality into workflows. Applicable for protocol discovery, collaborative protocol development, experiment tracking, lab protocol management, and scientific documentation.
Analyzes job descriptions and generates tailored resumes that highlight relevant experience, skills, and achievements to maximize interview chances
Generate Excalidraw diagrams from natural language descriptions. Use when asked to "create a diagram", "make a flowchart", "visualize a process", "draw a system architecture", "create a mind map", or "generate an Excalidraw file". Supports flowcharts, relationship diagrams, mind maps, and system architecture diagrams. Outputs .excalidraw JSON files that can be opened directly in Excalidraw.
Build and distribute Expo development clients locally or via TestFlight
Use when you have a written implementation plan to execute in a separate session with review checkpoints
Data structure for annotated matrices in single-cell analysis. Use when working with .h5ad files or integrating 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.
Benchling R&D platform integration. Access registry (DNA, proteins), inventory, ELN entries, workflows via API, build Benchling Apps, query Data Warehouse, for lab data management automation.
Comprehensive molecular biology toolkit. Use for sequence manipulation, file parsing (FASTA/GenBank/PDB), phylogenetics, and programmatic NCBI/PubMed access (Bio.Entrez). Best for batch processing, custom bioinformatics pipelines, BLAST automation. For quick lookups use gget; for multi-service integration use bioservices.
Take biotender-max/scrna-preprocessing-clustering from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.