VIEW THIS AS

Auto mode follows the Route Engine until you choose a viewpoint.

YOU ARE HERE

ROUTE CHECK

CONNECTED TO

WHAT NEXT

Use the canonical route for this room, or HELP if you are unsure.

Why Mathematics? | scVI for Single-Cell Counts: Negative Binomial Noise, Library Size, Latent Variables and Variational Inference

WHY MATHEMATICS?

Why Mathematics? | scVI for Single-Cell Counts: Negative Binomial Noise, Library Size, Latent Variables and Variational Inference

How scVI turns sparse single-cell RNA counts into a probabilistic model of cell state, sequencing depth and batch effects, using neural networks and variational inference without pretending that denoised values are direct measurements.

Why mathematics is important becomes easier to see when a real decision depends on it. This guide follows the mechanism from definitions and dimensions to a worked calculation, validation, practical learning and responsible use. It keeps factual evidence separate from interpretation and treats every illustrative scenario as an example rather than a promise of results.

Choose a reading route

  • Model count variability with negative binomial probability
  • Separate library size, batch and latent cell state
  • Optimize an evidence lower bound with reparameterized samples
  • Check denoising, integration and differential evidence responsibly

Chapter map

  1. 1. Count matrix and batches
  2. 2. Cell-state prior
  3. 3. Library-size factor
  4. 4. Normalized gene frequencies
  5. 5. Negative binomial mean
  6. 6. Zero-inflation gate
  7. 7. Batch-conditioned decoder
  8. 8. Encoder posterior
  9. 9. Reparameterization trick
  10. 10. Evidence lower bound
  11. 11. Stochastic minibatches
  12. 12. Latent-space distance
  13. 13. Posterior normalized expression
  14. 14. Worked one-gene count
  15. 15. Bayesian differential evidence
  16. 16. Governance and learning

Visit the How Mathematics Works hub for the wider series and its connections to education, reasoning, science, computing, design and careers.


1. Count matrix and batches

This is where modelling choices begin to affect evidence. X stores nonnegative UMI counts for N cells and G genes, while s records an optional batch category.

A concrete situation

A matrix has 5,000 cells by 2,000 genes in three batches.

What the mathematics does not license

Filtering changes the statistical population. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Publish dimensions and exclusions. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


2. Cell-state prior

The central mathematical idea is concrete. Each cell latent vector z is assigned a standard multivariate normal prior.

A concrete situation

A ten-dimensional vector begins around zero with unit variance.

What the mathematics does not license

A simple prior shapes geometry. The habit of checking assumptions is one of the practical benefits of learning mathematics.

Try it, check it, transfer it

Inspect posterior versus prior. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


3. Library-size factor

Here the geometry becomes operational. A positive scalar l captures cell-specific sequencing depth or capture efficiency separately from composition.

A concrete situation

Two similar cells have 2,000 and 8,000 UMIs.

What the mathematics does not license

Depth can correlate with cell type. The same reasoning helps students move from an exercise to a real dataset.

Try it, check it, transfer it

Stratify factors by biology. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


4. Normalized gene frequencies

This step deserves a careful pause. A decoder maps z and batch to a nonnegative gene vector rho that commonly sums to one.

A concrete situation

One cell allocates 4% of normalized mass to gene A.

What the mathematics does not license

A frequency is not an absolute molecule count. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Retain units and scale. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.

Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.


5. Negative binomial mean

The useful question is not only how to calculate, but what the calculation assumes. The mean for gene g combines library size l with frequency rho_g; inverse dispersion theta controls extra variance.

A concrete situation

Mean four and moderate dispersion allow zero, four or ten counts.

What the mathematics does not license

Dispersion choices affect tails. The habit of checking assumptions is one of the practical benefits of learning mathematics.

Try it, check it, transfer it

Check each abundance band. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


6. Zero-inflation gate

A small example makes the mechanism visible. When ZINB is selected, a learned probability mixes structural zero output with the negative binomial count process.

A concrete situation

A zero receives probability from two paths.

What the mathematics does not license

Zero inflation may be unnecessary for UMI data. The same reasoning helps students move from an exercise to a real dataset.

Try it, check it, transfer it

Compare NB and ZINB. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


7. Batch-conditioned decoder

This is where modelling choices begin to affect evidence. Batch one-hot values enter the decoder so technical shifts need not be stored entirely in z.

A concrete situation

The same z decodes differently for batches A and B.

What the mathematics does not license

Batch can be confounded with condition. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Use balanced designs. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


8. Encoder posterior

The central mathematical idea is concrete. A neural encoder estimates a mean and variance for q(z given x, s) and, in some configurations, q(l given x).

A concrete situation

One cell receives ten means and ten scales.

What the mathematics does not license

Diagonal Gaussian assumptions miss some dependence. The habit of checking assumptions is one of the practical benefits of learning mathematics.

Try it, check it, transfer it

Check posterior diagnostics. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.

Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.


9. Reparameterization trick

Here the geometry becomes operational. A latent sample is written as mean plus scale times standard normal noise so gradients pass through sampling.

A concrete situation

z equals mu plus sigma epsilon.

What the mathematics does not license

Few samples create Monte Carlo noise. The same reasoning helps students move from an exercise to a real dataset.

Try it, check it, transfer it

Repeat draws and seeds. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


10. Evidence lower bound

This step deserves a careful pause. Expected count log likelihood minus KL divergences forms a tractable lower bound on log evidence.

A concrete situation

Better reconstruction competes with posterior complexity.

What the mathematics does not license

One scalar hides per-gene errors. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Report each term. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


11. Stochastic minibatches

The useful question is not only how to calculate, but what the calculation assumes. Gradient estimates from cell subsets make optimization scale to large datasets.

A concrete situation

A 128-cell batch updates millions of parameters.

What the mathematics does not license

Non-random batches bias gradients. The habit of checking assumptions is one of the practical benefits of learning mathematics.

Try it, check it, transfer it

Audit sampler composition. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


12. Latent-space distance

A small example makes the mechanism visible. Posterior summaries place cells in a low-dimensional geometry used for neighbours, visualization and clustering.

A concrete situation

Two related immune cells lie close.

What the mathematics does not license

Distance depends on model and metric. The same reasoning helps students move from an exercise to a real dataset.

Try it, check it, transfer it

Repeat seeds and embeddings. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.

Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.


13. Posterior normalized expression

This is where modelling choices begin to affect evidence. Decoder samples estimate a distribution for batch-conditioned normalized abundance.

A concrete situation

Gene A has posterior mean 0.03 with an interval.

What the mathematics does not license

Denoising can smooth rare signals. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Report calibration and raw counts. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


14. Worked one-gene count

The central mathematical idea is concrete. Calculate a negative binomial probability for x=3 under a chosen mean and dispersion, then compare it with a Poisson probability.

A concrete situation

The negative binomial assigns more mass to a tail count.

What the mathematics does not license

One gene ignores covariance. The habit of checking assumptions is one of the practical benefits of learning mathematics.

Try it, check it, transfer it

Repeat over a count range. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


15. Bayesian differential evidence

Here the geometry becomes operational. Posterior samples compare decoded expression between groups and estimate an effect probability or Bayes factor.

A concrete situation

P(log fold change greater than delta) is 0.95.

What the mathematics does not license

Group and threshold choices matter. The same reasoning helps students move from an exercise to a real dataset.

Try it, check it, transfer it

Publish effect sensitivity. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.


16. Governance and learning

This step deserves a careful pause. Version counts, genes, batches, likelihood, library rule, latent width and posterior decision. This joins probability, statistics and AI.

A concrete situation

Students can begin with Poisson versus negative binomial.

What the mathematics does not license

A latent coordinate is a model result. That distinction matters because a correct formula can still answer the wrong operational question.

Try it, check it, transfer it

Write a scVI evidence card. Then explain the result to someone who has not seen the formula. If the explanation needs a hidden assumption, add that assumption to the model record.

Did You Know? In this chapter, the most important number is useful only together with its construction rule. Changing scaling, sample membership or validation design can change the numerical answer without changing the arithmetic.


A seven-day practice lab

  1. Day 1: define the decision, observation unit, X variables and Y or reference condition.
  2. Day 2: reproduce the smallest worked example and check every dimension, unit and sign.
  3. Day 3: build a transparent baseline and write what it assumes.
  4. Day 4: fit the main method inside a training-only pipeline; record every parameter.
  5. Day 5: challenge one assumption with a deliberately difficult dataset or operating regime.
  6. Day 6: compare validation metrics with the practical workload created by errors.
  7. Day 7: present one supported conclusion, one unresolved uncertainty and one safe next experiment.

Questions for a student, parent or mentor

  • Which part of the model is a mathematical definition, and which part is a choice?
  • What small calculation would catch a sign, scale or dimension error?
  • What evidence comes from training, validation and the untouched test?
  • What benign condition could look like a fault or prediction failure?
  • How would the answer change for another response, asset, school project or time period?
  • What should a human review before acting on the score?

A method-specific audit before deployment

A scVI audit begins with a cell-by-gene count matrix, batch labels and an observation model. Each cell receives a low-dimensional latent state and a library-size factor. A neural decoder turns latent state and batch into normalized gene frequencies, while a negative binomial or zero-inflated negative binomial distribution represents overdispersed counts. Variational inference replaces an intractable posterior with a trainable approximation.

Record raw UMI counts, genes, batches, filtering, likelihood family, dispersion mode, observed or latent library size, latent dimension, encoder and decoder architecture, priors, evidence lower bound, training split and posterior sampling rule. Current scvi-tools documentation permits negative binomial or zero-inflated negative binomial choices and may treat library size as observed, so the deployed configuration must be stated rather than inferred from an old default.

Validate with posterior predictive checks, complete-batch holdouts, simple PCA and count baselines, latent leakage tests and differential-expression sensitivity. A denoised frequency, latent coordinate or posterior probability is an estimate under the model. It should accompany raw counts, uncertainty and assumptions rather than replace them.


Frequently asked questions

What is scVI?

scVI means single-cell Variational Inference. It is a probabilistic deep generative framework for representing and analysing single-cell RNA count data while accounting for uncertainty, sequencing depth and optional batch annotations.

Why use a negative binomial distribution?

Single-cell gene counts are usually more variable than a Poisson model allows. A negative binomial adds a dispersion parameter, so its variance can exceed its mean.

What is zero inflation?

A zero-inflated model adds a separate mechanism that can create extra zeros. The original paper used a ZINB form; current implementations can also use a negative binomial, so the chosen likelihood must be reported.

What does the latent variable mean?

The cell-specific vector z is a compact model representation intended to capture remaining variation after declared technical factors. Its axes are learned coordinates, not named biological measurements.

What is the evidence lower bound?

The ELBO combines expected reconstruction log likelihood with penalties that keep approximate posterior distributions near their priors. Maximizing it fits both the generative model and the inference networks.

Does scVI make batch-corrected values true expression?

No. Denoised and batch-conditioned outputs are posterior estimates. Raw counts, preprocessing, model configuration, uncertainty and external evidence remain necessary.


Primary source and fact-check note

Romain Lopez, Jeffrey Regier, Michael B. Cole et al., “Deep generative modeling for single-cell transcriptomics,” Nature Methods 15, 1053–1058 (2018), DOI 10.1038/s41592-018-0229-2. Definitions and core claims in this article were checked against this primary publication. Calculations shown here were independently recomputed. Examples are educational illustrations; they are not reported industrial performance results.

Useful next reading

Keep the options open. Mathematics education supports clearer questions, transferable problem-solving skills and informed choices across science, engineering, computing, AI, statistics, design and many other careers. It does not guarantee intelligence, income, admission or employment; those outcomes depend on far more than one subject or model.

Extended laboratory: topic-specific validation and responsible use

Count provenance

Store raw UMI layer, gene IDs, filtering, donor, batch and preprocessing version.

Likelihood comparison

Compare Poisson, NB and ZINB predictive residuals instead of assuming one family.

Library-size audit

State whether depth is observed, latent or supplied; test correlations with biology.

Loss ledger

Report reconstruction and every KL term by gene abundance and batch.

Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.

Latent leakage

Measure predictability of batch, depth and quality from z alongside biological conservation.

Differential sensitivity

Vary priors, effect thresholds, grouping, samples and dispersion settings.

External holdout

Reserve complete donors and batches from model and decision tuning.

Final claim

Name count layer, likelihood, library rule, batches and posterior decision. Denoised output is estimated.

Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.

Mechanism workshop: calculate, challenge and transfer

Workshop 1: Count matrix and batches

Start with this article's mechanism: X stores nonnegative UMI counts for N cells and G genes, while s records an optional batch category. Work through the concrete case: A matrix has 5,000 cells by 2,000 genes in three batches. Make the boundary visible: Filtering changes the statistical population. Complete the evidence step: Publish dimensions and exclusions. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 2: Cell-state prior

Start with this article's mechanism: Each cell latent vector z is assigned a standard multivariate normal prior. Work through the concrete case: A ten-dimensional vector begins around zero with unit variance. Make the boundary visible: A simple prior shapes geometry. Complete the evidence step: Inspect posterior versus prior. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 3: Library-size factor

Start with this article's mechanism: A positive scalar l captures cell-specific sequencing depth or capture efficiency separately from composition. Work through the concrete case: Two similar cells have 2,000 and 8,000 UMIs. Make the boundary visible: Depth can correlate with cell type. Complete the evidence step: Stratify factors by biology. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 4: Normalized gene frequencies

Start with this article's mechanism: A decoder maps z and batch to a nonnegative gene vector rho that commonly sums to one. Work through the concrete case: One cell allocates 4% of normalized mass to gene A. Make the boundary visible: A frequency is not an absolute molecule count. Complete the evidence step: Retain units and scale. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.

Workshop 5: Negative binomial mean

Start with this article's mechanism: The mean for gene g combines library size l with frequency rho_g; inverse dispersion theta controls extra variance. Work through the concrete case: Mean four and moderate dispersion allow zero, four or ten counts. Make the boundary visible: Dispersion choices affect tails. Complete the evidence step: Check each abundance band. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 6: Zero-inflation gate

Start with this article's mechanism: When ZINB is selected, a learned probability mixes structural zero output with the negative binomial count process. Work through the concrete case: A zero receives probability from two paths. Make the boundary visible: Zero inflation may be unnecessary for UMI data. Complete the evidence step: Compare NB and ZINB. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 7: Batch-conditioned decoder

Start with this article's mechanism: Batch one-hot values enter the decoder so technical shifts need not be stored entirely in z. Work through the concrete case: The same z decodes differently for batches A and B. Make the boundary visible: Batch can be confounded with condition. Complete the evidence step: Use balanced designs. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 8: Encoder posterior

Start with this article's mechanism: A neural encoder estimates a mean and variance for q(z given x, s) and, in some configurations, q(l given x). Work through the concrete case: One cell receives ten means and ten scales. Make the boundary visible: Diagonal Gaussian assumptions miss some dependence. Complete the evidence step: Check posterior diagnostics. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.

Workshop 9: Reparameterization trick

Start with this article's mechanism: A latent sample is written as mean plus scale times standard normal noise so gradients pass through sampling. Work through the concrete case: z equals mu plus sigma epsilon. Make the boundary visible: Few samples create Monte Carlo noise. Complete the evidence step: Repeat draws and seeds. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 10: Evidence lower bound

Start with this article's mechanism: Expected count log likelihood minus KL divergences forms a tractable lower bound on log evidence. Work through the concrete case: Better reconstruction competes with posterior complexity. Make the boundary visible: One scalar hides per-gene errors. Complete the evidence step: Report each term. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 11: Stochastic minibatches

Start with this article's mechanism: Gradient estimates from cell subsets make optimization scale to large datasets. Work through the concrete case: A 128-cell batch updates millions of parameters. Make the boundary visible: Non-random batches bias gradients. Complete the evidence step: Audit sampler composition. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 12: Latent-space distance

Start with this article's mechanism: Posterior summaries place cells in a low-dimensional geometry used for neighbours, visualization and clustering. Work through the concrete case: Two related immune cells lie close. Make the boundary visible: Distance depends on model and metric. Complete the evidence step: Repeat seeds and embeddings. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Did You Know? A sophisticated adjustment can be algebraically correct and still answer the wrong scientific question when samples, labels, batches or validation boundaries are wrong.

Workshop 13: Posterior normalized expression

Start with this article's mechanism: Decoder samples estimate a distribution for batch-conditioned normalized abundance. Work through the concrete case: Gene A has posterior mean 0.03 with an interval. Make the boundary visible: Denoising can smooth rare signals. Complete the evidence step: Report calibration and raw counts. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 14: Worked one-gene count

Start with this article's mechanism: Calculate a negative binomial probability for x=3 under a chosen mean and dispersion, then compare it with a Poisson probability. Work through the concrete case: The negative binomial assigns more mass to a tail count. Make the boundary visible: One gene ignores covariance. Complete the evidence step: Repeat over a count range. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 15: Bayesian differential evidence

Start with this article's mechanism: Posterior samples compare decoded expression between groups and estimate an effect probability or Bayes factor. Work through the concrete case: P(log fold change greater than delta) is 0.95. Make the boundary visible: Group and threshold choices matter. Complete the evidence step: Publish effect sensitivity. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.

Workshop 16: Governance and learning

Start with this article's mechanism: Version counts, genes, batches, likelihood, library rule, latent width and posterior decision. This joins probability, statistics and AI. Work through the concrete case: Students can begin with Poisson versus negative binomial. Make the boundary visible: A latent coordinate is a model result. Complete the evidence step: Write a scVI evidence card. Write the count matrix, binary region table, differential equation or spatial mixture, then name every unit, probability assumption, latent variable and uncertainty source. Repeat under a nearby defensible setting and compare negative binomial tails, library factors, Bernoulli products, kinetic derivatives, posterior signs, cell-type proportions or residual maps as relevant. Use complete donors, studies, batches, time points or tissue sections outside training when testing transfer, because random cells from one biological source are not independent evidence. Keep measurement, model estimate, interpretation and decision on separate notebook lines so a student, parent or reviewer can see what the mathematics establishes.