Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Quantification

What it does

Each cell becomes one row of a table: for every marker, the intensity of the pixels inside the cell (mean, median and standard deviation by default), plus the cell’s size and shape.

Parameters

How it works

For every marker, all the pixels inside the cell’s outline, holes excluded, are summarised. With nuclei linked to cells, the same is done for the nucleus compartment and the cytoplasm. The image is read in 2048 px tiles; a cell belongs to the tile holding its centre, and that tile grows to cover it, so every cell is measured whole. The segmentation patches are not reused, so the patch size never changes the table.

Shape features are measured on the outline itself, not on pixels:

Shape featureMeaning
area, perimeterin px² and px
circularity4π × area / perimeter²; 1 for a circle; empty below 30 px²
solidityarea / area of the convex hull
eccentricityof the ellipse with the same second moments; 0 for a circle
major, minor axislengths of that ellipse’s axes
nc_rationucleus area / cell area, with linked nuclei

Areas and lengths are in pixels; convert with the pixel size in the stitched OME-TIFF. An empty value (NaN) means “not measured”, 0 means “measured, nothing there”. Cells are never dropped.

Inputs and outputs. In: the full image and one method’s cell outlines (and nuclei and cytoplasm, when linked). Out: one table per method, {m}_table, in the store. Columns are named {marker}_{statistic}, e.g. CD3_mean; the nucleus and cytoplasm values sit in two extra layers, nucleus and cytoplasm; shape features are per-cell annotations. Values are 32-bit floats. See The SpatialData store.

Similar tools

This step is sopa’s, with one fix: sopa’s mask drawing ignores holes, so a cytoplasm ring would be measured as the whole cell. Here holes are cut out. Mean is the baseline, since no benchmark ranks statistics for phenotyping; median and quartiles are the usual extras. q99 is not offered: in a 50-pixel cell it is the maximum. min and max are mostly background and hot pixels, so they are off by default.

Read more

Version used:

ModuleToolVersionContainerPaper
AGGREGATEsopa2.3.0docker.io/josenimo/sopa:2.3.0-1Blampey et al. (2024)
References
  1. Schapiro, D., Sokolov, A., Yapp, C., Chen, Y.-A., Muhlich, J. L., Hess, J., Creason, A. L., Nirmal, A. J., Baker, G. J., Nariya, M. K., Lin, J.-R., Maliga, Z., Jacobson, C. A., Hodgman, M. W., Ruokonen, J., Farhi, S. L., Abbondanza, D., McKinley, E. T., Persson, D., … Sorger, P. K. (2021). MCMICRO: a scalable, modular image-processing pipeline for multiplexed tissue imaging. Nature Methods, 19(3), 311–315. 10.1038/s41592-021-01308-y
  2. Blampey, Q., Mulder, K., Gardet, M., Christodoulidis, S., Dutertre, C.-A., André, F., Ginhoux, F., & Cournède, P.-H. (2024). Sopa: a technology-invariant pipeline for analyses of image-based spatial omics. Nature Communications, 15(1). 10.1038/s41467-024-48981-z