← Về thư mục
📄 / / profiles / r-and-d / raw_evidence / OpenAI4S / skills / bioskills / bio-flow-cytometry-gating-analysis / references / usage-guide.md

Gating Analysis - Usage Guide

Overview

Gating defines cell populations by drawing boundaries in marker space, organized as a hierarchy. This skill covers manual gates (rectangle, polygon, quadrant, boolean) and reproducible automated gating (openCyto templates, flowDensity, flowClust), the canonical gate order that operates as a contamination funnel (time -> debris -> singlets -> live -> lineage), and the expert essentials: FMO (not isotype) controls set positive/negative boundaries because spreading error dominates them, hierarchical gates must be recomputed and live on the transformed scale, and rare-event/MRD work stays supervised because clustering fails for ultra-rare populations.

Prerequisites

# R/Bioconductor
BiocManager::install(c('flowWorkspace', 'openCyto', 'flowDensity', 'flowCore', 'CytoML', 'ggcyto'))

Quick Start

Tell your AI agent what you want to do: - "Gate lymphocytes, singlets, live cells, then CD4/CD8 T cells" - "Automate my FlowJo gating strategy across all samples with openCyto" - "Set the CD25 positive boundary using my FMO control" - "Gate a rare MRD population and tell me how many cells I need to acquire"

Example Prompts

Manual hierarchy

"Build a standard T-cell hierarchy on my GatingSet: debris on FSC/SSC, singlets on FSC-A vs FSC-H, live on the viability channel, then a CD4/CD8 quadrant on CD3+ cells - and remember to recompute before pulling counts." "Set up a boolean gate for CD4+ AND NOT CD8+ and extract its frequency per sample."

Automated and reproducible

"Turn this manual gating scheme into an openCyto CSV template and apply it to all 40 samples; use mindensity for the bimodal markers and flowClust for the CD4/CD8 split." "Use flowDensity to reproduce my predefined sequential gating strategy automatically."

Boundaries and rare events

"Use my FMO controls to set the positive boundaries for CD25 and CD69 - explain why isotype controls would be wrong here." "I need MRD sensitivity of 1e-5 - how many cells must I acquire, and why shouldn't I use clustering for this?"

What the Agent Will Do

  1. Build a GatingSet and add gates in the canonical funnel order.
  2. Set positive/negative boundaries from FMO controls where available.
  3. Recompute the hierarchy and confirm gates are on the data's (transformed) scale.
  4. For automation, write an openCyto template or apply flowDensity, verifying method names against the installed version.
  5. Extract per-population statistics or export gated populations / FlowJo workspaces.

Tips