scired

Interprets scRNA-seq factor analysis via Poisson-GLM residualisation, PCA, varimax rotation, and factor-covariate scoring.

1|Updated Nov 20, 2025
One-click install
npx skills add https://github.com/tony-zhelonkin/scio --skill scired-tony-zhelonkin
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: scired
Source: https://github.com/tony-zhelonkin/scio/tree/main/skills/scired
Command: npx skills add https://github.com/tony-zhelonkin/scio --skill scired-tony-zhelonkin

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires sciRED, numpy, pandas, scanpy, statsmodels, scikit-learn, xgboost, scipy, seaborn, matplotlib, umap-learn, scikit-image, diptest, and includes references (resource) components.

What problem does it solve? Single-cell RNA-seq factor analysis produces latent factors that are hard to interpret: which factors track which biological covariates, which genes drive each factor, and which technical confounders contaminate the decomposition. This Skill operationalises the sciRED Python package to residualise known confounders, extract varimax-rotated factors, and rank factor-covariate associations with a supervised scoreboard. ## Core Features & Use Cases - Confounder residualisation: Fits per-gene Poisson GLMs against a design matrix of technical covariates (library size, protocol, batch) and passes Pearson residuals to PCA. - Varimax-rotated factors: Produces sparse, interpretable gene loadings with rotated cell scores for marker-gene readout. - FCAT and FIST scoreboards: Trains classifier ensembles (LogReg, DecisionTree, XGBoost) to rank factor-covariate associations and combines bimodality, variance, and specificity metrics into an interpretability clustermap. - Use Case: Given an AnnData object with raw counts and cell-type metadata, run the four-step pipeline to discover that factor F3 tracks the stimulated condition while F7 separates cell lines, then export loadings and scores as CSVs. ## Quick Start Use the scired skill to run the sciRED pipeline on my AnnData object with raw counts, residualising library size and protocol, then rank factors against the cell_line covariate.

Frequently Asked Questions about scired

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

FAQPage Schema
How do I interpret factors from scRNA-seq factor analysis?▼

Run the sciRED four-step pipeline: residualise counts with per-gene Poisson GLMs, run PCA on Pearson residuals, apply varimax rotation, then compute FCAT to rank each factor's association with covariate levels using a classifier ensemble. FIST combines bimodality, variance, and specificity metrics into a clustermap.

sciRED vs MOFA for single-cell factor analysis?▼

sciRED fits a single-omic count matrix with residualise-then-PCA and a supervised factor-covariate scoreboard. MOFA (mofa-mofapy2) handles multi-view multi-omic data such as RNA plus ATAC plus methylation in one joint model, so choose it when integrating multiple assays.

Can I pass log-normalised data to sciRED's Poisson GLM?▼

No. The poissonGLM function expects raw integer counts because it fits a Poisson likelihood per gene. Pass raw counts and apply log1p downstream only if another consumer needs log-scale values.

Why do varimax factor signs and orders change between runs?▼

Varimax rotation is non-unique due to SVD sign indeterminacy and rotation ambiguity. Force a canonical sign by flipping each factor so its largest-absolute loading is positive, and reorder factors by post-rotation variance for run-to-run comparability.

When should I not use sciRED?▼

Avoid sciRED for multi-omic integration (use MOFA), pseudo-bulk with under ~100 samples (PCA becomes rank-deficient and FCAT scores meaningless), nonlinear manifold visualisation (use UMAP), or datasets beyond roughly 100k cells where the sequential per-gene GLM loop becomes the bottleneck.