StrataQuest Home › StrataQuest Glossary › Phenotype Interactions
Spatial Engine

Phenotype Interactions

Analyzing spatial relationships between cell populations

View
Definition
Phenotype Interactions answers questions such as how many CK+ epithelial cells sit within 30 µm of each CD4+ T cell. You choose a primary phenotype, a secondary phenotype and a distance interval; an interaction is one cell of each inside that interval. For every primary cell the engine reports how many secondary cells are in range, their mean, closest and farthest distance, and the closest one's ID. Only the primary phenotype is measured.
Supporting
TQ to SQ workflow
Video · Supporting
Diagrams - Set Cut-Off - BW FW Connection V2
Video · Supporting
Diagrams - How to create Phenotype Diagrams V2
Video · Supporting
Pre processing - Advanced - Phenotype Interaction
Video · Supporting
Pre processing - Import - Coded Image
Video · Supporting
Primary and Secondary
The question has a direction
Distance Interval
Minimum to maximum distance
Five Per-Cell Measurements
Count, distances, closest ID
Counts, Not Statistics
Chance is a separate question

How It Works

An interaction is a pair of cells, one from the primary phenotype and one from the secondary, whose distance lies between Minimum Distance and Maximum Distance. The User Manual describes the purpose as finding connections between cells of two phenotypes, shown as lines joining the interacting cells, with the numbers available for scattergrams.

  1. Choose the phenotypes. The primary phenotype is the one that gets measured; the secondary phenotype is what it is measured against. Both come from the gating you did in diagrams (see phenotypesLoading...).
  2. Set the interval. A minimum of 0 counts every secondary cell closer than the maximum. A nonzero minimum makes a ring, for example 10–20 µm.
  3. Measure each primary cell. The engine finds the secondary cells inside the interval and records how many there are, their mean distance, the closest and farthest distance, and the ID of the closest one.
  4. Draw the interactions. The output shows every interaction or, with Draw Only Closest Interaction checked, only each primary cell's closest one.

The engine is found in two places in a layerLoading...: Pre-Processing, under Operations (advanced), and Measurements, under Measurements (advanced); the menu reads "Phenotypes Interactions". The per-cell measurements are produced only when it is used in Measurements. One instance handles one pair of phenotypes, so each further pair or interval is another instance.

Simplified

Pick two cell types and a distance. For each cell of the first type, the engine counts the cells of the second type within that distance and notes how far away they are. The result is a number per cell, which you can plot and gate like any other measurement.

Science Behind It

What the numbers are. Count in Range is a neighbor count: for one primary cell, how many secondary cells fall inside a disk or ring around it. Minimum Range is that cell's nearest-neighbor distance to the other phenotype, limited to the interval. Both belong to single cells, so they can be gated, averaged per region, or compared between samples like intensity or area.

What they are not. A high count can mean two cell types are drawn to each other, or only that both are crowded into the same dense region. Spatial statistics generally separates those cases by comparing observed counts with counts from randomized arrangements, for example permuted cell-type labels or Ripley's cross-K function. Phenotype Interactions does not make that comparison; it gives the observed counts such a test starts from. A rough check inside StrataQuest is to set each count beside the local density of the secondary population, which Density of EventsLoading... maps.

Why distance intervals. Cells in contact and cells within signaling range are different biology. Stepping the interval in rings, as the Engines Reference does with 0–10, 10–20, 20–30 and 30–40 µm, shows whether neighbors concentrate close to each cell or spread evenly with distance. Comparing open ranges instead (0–10, 0–20, 0–30 and 0–40 µm, the reference's third example) shows the same thing as a running total.

Neighbors versus landmarks. Phenotype Interactions measures cell to cell. When the question is distance to a structure, such as the tumor edge, distance mapsLoading... and Proximity AreasLoading... answer it; when it is "inside" rather than "near", Events Count Inside Master Events counts the events within each larger event.

Simplified

The engine counts neighbors; it does not say whether those counts are more than chance. Two cell types packed into the same crowded area score high even if they ignore each other. Telling attraction from crowding takes a statistical comparison the engine does not make.

Parameters & Settings

ParameterDescription
Primary PhenotypeThe phenotype that is measured.
Secondary PhenotypeThe phenotype it interacts with. It gets no measurements.
Minimum DistanceLower edge of the interaction interval. Use 0 for all interactions under the maximum.
Maximum DistanceUpper edge of the interaction interval.
Selected measurementsCount in Range, Mean Range, Minimum Range, Maximum Range, Closest ID in Range. Measurements category only.
Draw Only Closest InteractionUnder the advanced parameters. Draws only the closest interaction for each primary cell.

The User Manual gives the maximum distance in µm, and its example uses 30 µm; the reference's figures run to 40 µm. Its figures come in two versions labeled "centers" and "nucl", and the text doesn't say whether distances run between cell centers or between nuclear outlines. If your cells are large relative to the interval, check which one your result uses.

Source: StrataQuest 8.1 Engines Reference, ch. 34 (pp. 483–494); User Manual §12.6.5 (p. 199).

Simplified

Leave Minimum Distance at 0 unless you want a ring. Set Maximum Distance to the scale you care about; the manual's example uses 30 µm. Check Draw Only Closest Interaction to show one connection per primary cell.

Practical Example

This follows the User Manual's own example: how actively CD4+ T cells engage the epithelium, in a section stained for CK and CD4.

  1. Set CD4+ T cells as the Primary Phenotype and CK+ epithelial cells as the Secondary.
  2. Set Minimum Distance to 0 and Maximum Distance to 30 µm, and select Count in Range and Minimum Range.
  3. Plot Count in Range on a scattergramLoading... and gateLoading... it into the manual's three classes: low activity (1–4 interactions), medium (4–8) and high (9 or more). Make adjacent gates meet without overlapping, since a cell may belong to two overlapping gates.
  4. Check each class with View Backward Data, then add the gates to the Statistics Report to count each class per region.
  5. For a distance profile, add instances with intervals of 0–10, 10–20, 20–30 and 30–40 µm and compare the counts ring by ring.

The gates show how many T cells have few, some or many epithelial neighbors within 30 µm. Whether that pattern is more than chance is a separate question.

Simplified

Make each CD4+ T cell the center and count the epithelial cells within 30 µm of it. Then group the T cells by that count: low, medium or high activity.

Connected Terms

Share This Term
Term Connections