This guide covers analyzing spatial proteomics data from CODEX, IMC, and MIBI platforms.
pip install scimap squidpy anndata scanpyTell your AI agent what you want to do:
- "Load and preprocess my CODEX data"
- "Phenotype cells based on marker expression"
- "Analyze spatial interactions between cell types"
- "Find cellular neighborhoods in my IMC data"
"Load my spatial proteomics h5ad file and normalize the marker intensities"
"Apply batch correction across my multiple FOVs"
"Phenotype cells as T cells, B cells, macrophages, and tumor cells based on canonical markers"
"Cluster my cells and annotate clusters based on marker expression"
"Calculate spatial interactions between tumor and immune cells"
"Identify cellular neighborhoods and their composition"
"Find which cell types are enriched near tumor boundaries"
"Create a spatial plot colored by cell phenotype"
"Generate a heatmap of cell-cell spatial interactions"
- Load spatial proteomics data into AnnData format
- Preprocess and normalize marker intensities
- Perform cell phenotyping (gating or clustering)
- Build spatial neighbor graphs
- Calculate spatial statistics and interactions
- Generate visualizations
- Normalize markers before phenotyping
- Use rescale to make markers comparable
- Set reasonable gating thresholds (often 0.5 after rescale)
- Consider k-nearest neighbors (k=10-30) for spatial analysis
- Compare spatial patterns across multiple FOVs
- Integrate with transcriptomics if available