Bayesian Kinetics: Fitting Caspase-3 Progress Curves with PyMC

Python
Data Science
Chemical Engineering
Author

Mohammad Savarmand

Published

2026 October 15

Creators

This project uses the dataset accompanying “A simple linearization method unveils hidden enzymatic assay interferences,” created by Maria Filipa Pinto, Jorge Ripoll-Rozada, Helena Ramos, Emma E. Watson, Charlotte Franck, Richard J. Payne, Lucília Saraiva, Pedro José Barbosa Pereira, Annalisa Pastore, Fernando Rocha, and Pedro M. Martins.

The dataset is titled “Catalysis of Ac-DEVD-AMC by caspase-3 (dataset formatted for analysis by interferENZY).”

License

The source material is licensed under Creative Commons Attribution 4.0 International (CC BY 4.0). The license text is available at https://creativecommons.org/licenses/by/4.0/legalcode.

Disclaimer of warranties

Disclaimer of warranties: The source material is provided “as-is” and “as-available,” without warranties, to the extent permitted by law. See Section 5 of the CC BY 4.0 license for the full disclaimer of warranties and limitation of liability.

Links to the dataset and article

Source: Link to Dataset | Link to Article

Modifications

I renamed the dataset file, removed the first five metadata lines, and added custom column names. I preserved the original tab-separated format and measurement values. I documented additional data-processing steps in the Python code in the GitHub Repo.

1 TL;DR

Model 5

I used a published dataset tracking how fast an enzyme (caspase-3) converts its substrate into product at five different starting substrate amounts. I fitted the standard textbook equation for enzyme speed (Michaelis–Menten) to the dataset using Bayesian statistics, so each fitted parameter comes out as a list of numbers with an attached probability, rather than a single calculated number.

  • I fit six PyMC models of increasing complexity, with each change incrementally fixing issues in the previous model.
  • The best model (Model 5) gives \(V_{\max} = 118.9 \pm 1.3\) µM/hour and \(K_m = 23.1 \pm 0.4\) µM, within about 9% of the article’s own values.
  • Inverting the fit to predict “how long until the product reaches concentration X” reaches an \(R^2\) of 0.996 for the final use case.
  • Nothing here is specific to enzymes. The same workflow (write down the model, give its parameter priors, sample, check the fit) applies to any field with a trusted model and noisy data: pharmacokinetics, epidemiology, process engineering, economics, ecology.

2 Project Overview

2.1 Summary

I use Bayesian inference to estimate Michaelis–Menten parameters from caspase-3 assay data, then use the integrated equation to predict the time required to reach a target product concentration.

2.2 Motivation and Background

After graduating from NJIT with a bachelor’s in chemical engineering and a master’s in data science, I wanted to create a project that used both. After some thought, kinetics seemed like the best subject to combine skills for both degrees.

While reviewing kinetics, I realized that mathematical models can also be viewed as causal relationships (to a degree). As loose as that logic is, it reminded me of a topic I had been neglecting, Bayesian statistics. I first discovered this subject in 2021 through Richard McElreath’s book Statistical Rethinking, but I couldn’t learn it alongside my classes because I couldn’t manage both at once.

Now seems like a perfect time to learn through application.

2.3 Research Questions and Objectives

  • What are the Michaelis–Menten parameters, and how uncertain are their estimates?
  • Can those parameters predict the time to reach a specified product concentration, \(t(C_B)\)?

3 Bayesian Statistics Concepts

3.1 Quick Overview

  • Directed Acyclic Graphs (DAGs) show how variables depend on one another in a model. In the PyMC-generated graphs, an arrow means that one variable is used to calculate or define another. These graphs make the model’s structure easier to follow, but they do not, by themselves, prove causality.

    • DAGs are also used in other contexts, where arrows may represent different types of relationships, so their meaning depends on how the graph is defined.
  • Priors describe what parameter values are plausible before fitting the data. They are effectively informed guesses. For example, before measuring a plant, we might expect its height to be around 30 cm, with shorter or taller heights considered possible but less likely.

  • Posteriors describe what parameter values are plausible after combining the priors with the observed data through the likelihood. They are updated estimates that include uncertainty.

  • Likelihood describes how well different parameter values explain the observed data under the model. In this project, it measures how well the concentrations predicted by the Michaelis–Menten equation (the model’s backbone) agree with the measurements, given the assumed measurement noise.

The collapsible section below, “Similarities with linear regression,” provides additional explanation.

Prior Distributions, the Likelihood, and the Posterior

A familiar starting point is linear regression, where the predicted response is:

\[ y_{\mathrm{predicted}}=mx+b \]

The actual observation can differ from this prediction because of unexplained variation:

\[ y_{\mathrm{actual}}=y_{\mathrm{predicted}}+\epsilon \]

where \(m\) is the slope, \(b\) is the intercept, and \(\epsilon\) represents the error.

Ordinary least squares produces a single estimated value for each coefficient. Bayesian regression assigns probability distributions to the unknown coefficients to represent uncertainty about their values, then updates those distributions with the observations.

Bayes’ theorem describes this update:

\[ p(\theta\mid y) = \frac{p(y\mid\theta)\,p(\theta)}{p(y)} \]

where \(\theta\) contains the unknown parameters and \(y\) contains the observations. Because \(p(y)\) is constant with respect to \(\theta\) and often difficult to calculate, we can write:

\[ \underbrace{p(\theta\mid y)}_{\text{Posterior}} \propto \underbrace{p(y\mid\theta)}_{\text{Likelihood}} \underbrace{p(\theta)}_{\text{Prior}} \]

MCMC methods approximate the posterior through sampling without explicitly calculating \(p(y)\).

The comparison below illustrates how the same linear relationship can be expressed as a Bayesian model:

Component Ordinary least squares regression Bayesian linear regression
Parameters: \(\theta\) Unknown slope \(m\), intercept \(b\), and noise standard deviation \(\sigma\) \(\theta=(m,b,\sigma)\) groups the unknown parameters
Prior: \(p(\theta)\) No prior assigned What is believed about \(\theta\) before seeing the data, built from the two rows below
Prior on coefficients None. \(\hat m\) and \(\hat b\) are found later by minimizing \(\sum_i(y_i-\hat y_i)^2\) \(m\sim\operatorname{Normal}(0,s_m)\) and \(b\sim\operatorname{Normal}(0,s_b)\)
Prior on noise scale None. \(\hat\sigma=\sqrt{\frac{\sum_i(y_i-\hat y_i)^2}{n-2}}\) is computed after the fit, for simple linear regression with an intercept \(\sigma\sim\operatorname{HalfNormal}(s_\sigma)\)
Expected response \(\hat y_i=\hat m x_i+\hat b\) \(\mu_i=mx_i+b\)
Observations / likelihood: \(p(y\mid\theta)\) \(y_i=mx_i+b+\epsilon_i\), with \(\epsilon_i\sim\operatorname{Normal}(0,\sigma)\) under a normal-error model \(y_i\sim\operatorname{Normal}(\mu_i,\sigma)\)
Result / posterior: \(p(\theta\mid y)\) \(\hat m\), \(\hat b\), and \(\hat\sigma\), with coefficient uncertainty summarized by standard errors and confidence intervals A joint posterior for \(m\), \(b\), and \(\sigma\), with uncertainty summarized by posterior standard deviations and credible intervals

Here, the normal distributions are written using standard deviations, and \(s_m\), \(s_b\), and \(s_\sigma\) are chosen prior scales. The posterior notation applies only to the Bayesian column.

4 The Article

4.1 Brief Overview

The paper presents a modified linearized representation that makes unexpected behavior in enzyme kinetics easier to detect. Its experiments and simulations show why apparently good fits may not be sufficient quality checks.

For this project, I use the same starting point, the Michaelis–Menten equation, and data from one of their experiments, but take the analysis in a different direction to answer my own project objectives.

4.2 The Caspase-3 Assay

Assay: An experimental test used to detect or measure a substance or biological activity.

This Bayesian analysis uses the purified caspase-3 assay, where Ac-DEVD-AMC is cleaved to release fluorescent AMC. Product concentration was tracked at \(37^\circ\mathrm{C}\) using 1.0 U of enzyme and five initial substrate concentrations ranging from 3.125 to 50 \(\mu\mathrm{M}\). The authors identified the first ten minutes as a stabilization period to exclude from kinetic analysis.

I modeled the assay as a well-mixed batch reaction at constant temperature and volume, using the simplified conversion \(A\rightarrow B\) to track substrate consumption and AMC formation.

5 From Chemical Equation to Kinetics Differential Equation

5.1 Chemical Equation and Terms

The simplified equation is as follows:

\[ aA \rightarrow bB \]

  • \(a\) and \(b\) both equal 1, but I present them in the equation above for clarity later in the derivation.
  • \(C_{A0}\) is the concentration of the initial substrate (Ac-DEVD-AMC)
  • \(C_{B0}\) is the concentration of the initial product present (AMC)
  • \(C_B\) is the concentration of the product at any time (AMC)

5.2 Michaelis–Menten Kinetics

\[ -r_A=\frac{V_{\max}C_A}{K_m+C_A} \]

The article chooses to use the integrated form of the Michaelis-Menten equation as the basis for its kinetic analysis. After reading about the reaction’s characteristics, I also think the Michaelis-Menten relationship is an appropriate basis for Bayesian models in PyMC. But for my Bayesian models, I use the differential form of the kinetic equation. I derive it from the mole balance to make the underlying assumptions explicit, then integrate it to check that it agrees with the equation used in the article.

\[ \begin{alignedat}{2} F_{j0}-F_j+\int_0^V r_j\,dV &= \frac{dN_j}{dt} &&\quad (\text{Mole balance}) \\[6pt] \frac{dN_j}{dt} &= \int_0^V r_j\,dV &&\quad (\text{No inlet or outlet}) \\[6pt] \frac{dN_j}{dt} &= r_jV &&\quad (\text{Uniform reaction rate}) \\[6pt] \frac{1}{V}\frac{dN_j}{dt} &= \frac{dC_j}{dt}=r_j &&\quad (\text{Constant volume}) \end{alignedat} \]

Since \(aA \rightarrow bB\), \((a=b=1)\) our design equation is

\[ \frac{dC_B}{dt}=r_B=-r_A \]

Using the Michaelis-Menten equation,

\[ -r_A=\frac{V_{\max}C_A}{K_m+C_A} \]

Express product concentration in terms of conversion:

\[ \begin{alignedat}{2} C_B &= C_{B0}+(b/a)C_{A0}X &&\quad (\text{Starting equation 1}) \\[6pt] C_B &= C_{B0}+C_{A0}X &&\quad (b/a=1) \\[6pt] X &= \frac{C_B-C_{B0}}{C_{A0}} &&\quad (\text{Conversion}) \end{alignedat} \]

Substitute this into the substrate balance:

\[ \begin{alignedat}{2} C_A &= C_{A0}(1-X) &&\quad (\text{Starting equation 2}) \\[6pt] C_A &= C_{A0}-C_{A0}X &&\quad (\text{Expand}) \\[6pt] C_A &= C_{A0}-\cancel{C_{A0}} \bigg(\frac{C_B-C_{B0}}{\cancel{C_{A0}}}\bigg) &&\quad (\text{Substitute}) \\[6pt] C_A &= C_{A0}-(C_B-C_{B0}) &&\quad (\text{Simplify}) \end{alignedat} \]

Substitute into the rate equation and separate variables.

Use \(z\) as the integration variable for product concentration.

\[ \begin{alignedat}{2} \frac{dC_B}{dt} &= \frac{V_{\max}C_A}{K_m+C_A} &&\quad (\text{Michaelis-Menten}) \\[10pt] \frac{dC_B}{dt} &= \frac{V_{\max}[C_{A0}-(C_B-C_{B0})]} {K_m+C_{A0}-(C_B-C_{B0})} &&\quad (\text{⭐ Substitute } C_A) \\[10pt] \int_0^t V_{\max}\,d\tau &= \int_{C_{B0}}^{C_B} \frac{K_m+C_{A0}-(z-C_{B0})} {C_{A0}-(z-C_{B0})}\,dz &&\quad (\text{Separate variables}) \\[10pt] V_{\max}t &= \int_{C_{B0}}^{C_B} \bigg(1+\frac{K_m}{C_{A0}-(z-C_{B0})}\bigg)\,dz &&\quad (\text{Simplify}) \end{alignedat} \]

For the substitution and updated bounds:

\[ \begin{alignedat}{2} u &= C_{A0}-(z-C_{B0}) &&\quad (\text{Substitution}) \\[6pt] du &= -dz &&\quad (\text{Differentiate}) \\[6pt] u_{\mathrm{lower}} &= C_{A0}-(C_{B0}-C_{B0})=C_{A0} &&\quad (z=C_{B0}) \\[6pt] u_{\mathrm{upper}} &= C_{A0}-(C_B-C_{B0}) &&\quad (z=C_B) \end{alignedat} \]

Continue integrating:

\[ \begin{alignedat}{2} V_{\max}t &= \int_{C_{B0}}^{C_B}1\,dz -K_m\int_{C_{A0}}^{C_{A0}-(C_B-C_{B0})}\frac{1}{u}\,du &&\quad (\text{Substitute } u) \\[10pt] V_{\max}t &= (C_B-C_{B0}) -K_m\int_{C_{A0}}^{C_{A0}-(C_B-C_{B0})}\frac{1}{u}\,du &&\quad (\text{Integrate first term}) \\[10pt] V_{\max}t &= (C_B-C_{B0}) -K_m[\ln(u)]_{C_{A0}}^{C_{A0}-(C_B-C_{B0})} &&\quad (u>0) \\[10pt] V_{\max}t &= (C_B-C_{B0}) -K_m\big[\ln(C_{A0}-(C_B-C_{B0}))-\ln(C_{A0})\big] &&\quad (\text{Evaluate bounds}) \\[10pt] V_{\max}t &= (C_B-C_{B0}) -K_m\ln\bigg(\frac{C_{A0}-(C_B-C_{B0})}{C_{A0}}\bigg) &&\quad (\text{⭐ Log rule}) \end{alignedat} \]

To obtain the form with zero initial product concentration, set \(C_{B0}=0\):

\[ \begin{alignedat}{2} V_{\max}t &= (C_B-C_{B0}) -K_m\ln\bigg(\frac{C_{A0}-(C_B-C_{B0})}{C_{A0}}\bigg) &&\quad (\text{Starting equation}) \\[10pt] V_{\max}t &= C_B-K_m\ln\bigg(\frac{C_{A0}-C_B}{C_{A0}}\bigg) &&\quad (C_{B0}=0) \\[10pt] C_B &= V_{\max}t+K_m\ln\bigg(1-\frac{C_B}{C_{A0}}\bigg) &&\quad (\text{Rearrange}) \\[10pt] P &= V_{\max}t+K_m\ln\bigg(1-\frac{P}{S_0}\bigg) &&\quad (\text{⭐ Rename variables}) \end{alignedat} \]

\(P\) = Product concentration formed

\(V_{\max}\) = Maximum reaction rate

\(S_0\) = Initial substrate concentration

\(K_m\) = Michaelis constant

\[ \begin{alignedat}{2} \frac{dC_B}{dt} &= \frac{V_{\max}(C_{A0}-C_B)} {K_m+C_{A0}-C_B} &&\quad (\text{Differential equation used in the Bayesian models}) \\[12pt] t &= \frac{ (C_B-C_{B0}) -K_m\ln\left(\frac{C_{A0}-C_B}{C_{A0}-C_{B0}}\right) }{V_{\max}} &&\quad (\text{Equation used to predict time}) \\[12pt] P &= V_{\max}t+K_m\ln\left(1-\frac{P}{S_0}\right) &&\quad (\text{Agreement with the article when } C_{B0}=0) \end{alignedat} \]

These three equations serve different purposes.

The first equation lets PyMC calculate product concentrations over time and use the measurements to estimate the kinetic parameters.

The second uses those estimates to calculate the time to reach a chosen product concentration, \(C_B\).

I derived the third only to check that I reached the same equation as the authors. I do not use it elsewhere in the project.

6 Understanding the Model Structure

6.1 Model 1 Structure

I built six models, starting with Model 1, which uses the simplest assumptions. It includes the full time series, sets the initial product concentration to zero, and assumes no measurement offset.

Step Bayesian linear regression Model 1
Unknowns: \(\theta\) \(m,\ b,\ \sigma\) \(V_{\max},\ K_m,\ \sigma\)
Priors: \(p(\theta)\) \(m\sim\operatorname{Normal}(0,s_m)\), \(b\sim\operatorname{Normal}(0,s_b)\), \(\sigma\sim\operatorname{HalfNormal}(s_\sigma)\) \(V_{\max},K_m\sim\operatorname{LogNormal}(0,1)\), \(\sigma\sim\operatorname{HalfNormal}(1)\)
Expected response \(\mu_i=mx_i+b\) \(\mu_i=C_B(t_i)\), from the rate equation with \(C_{B0}=0\)
Likelihood, per observation \(y_i\sim\operatorname{Normal}(\mu_i,\sigma)\) \(y_i\sim\operatorname{Normal}(\mu_i,\sigma)\)

I fixed \(C_{B0}=0\) and \(C_{A0}=3.125\), so the model assumes no product is present initially and cannot adjust that value during fitting. Parameters with prior distributions, such as \(V_{\max}\) and \(K_m\), are instead estimated from the data.

6.2 Model 1 Tables

Parameter ESS bulk ESS tail R̂
\(V_{\max}\) 1204 907 1.001
\(K_m\) 1196 943 1.001
\(\sigma\) 1512 1525 1.001

Divergences: 0

Sampling diagnostics: These check whether the sampler explored the posterior properly before you trust the estimates.

  • ESS (effective sample size). MCMC draws are taken in sequence, so each one overlaps with its neighbors and repeats some of what they already said. ESS is computed after sampling and reports how many independent draws would carry the same information as the whole correlated set. For Model 1, the 4,000 draws carry as much information as about 1,200 independent draws would for \(V_{\max}\). Higher is better. With four chains, at least 400 is the minimum for stable means and interval endpoints.
    • Bulk ESS is the effective sample size for the main body of the posterior, which determines how well the mean and median are estimated.
    • Tail ESS is the effective sample size for the 2.5% and 97.5% quantiles, which determines how well the interval endpoints are estimated.
  • \(\hat R\) compares the spread within each chain to the spread between chains. Values near 1.00 mean all chains found the same posterior, and anything above 1.01 is a warning.
  • Divergences count the times the sampler failed to track the posterior and should be zero.

Model 1 interpretation: ESS is 900 to 1500 for every parameter, \(\hat R\) is 1.001, and there are no divergences, so the sampler worked and the estimates below can be read at face value.

Parameter Mean SD Relative SD (%) 95% lower 95% upper
\(V_{\max}\) (µM/hour) 92.04 31.29 34.0 49.46 168.88
\(K_m\) (µM) 19.41 7.18 37.0 9.58 37.20
\(V_{\max}/K_m\) (1/hour) 4.79 0.19 3.9 4.48 5.21
\(\sigma\) (µM) 0.117 0.008 6.9 0.103 0.134

Parameter estimates: Each row summarizes the posterior for one parameter.

  • Mean and standard deviation (SD) are the center and spread of the posterior draws.
  • Relative SD is the SD as a percentage of the mean, making uncertainty comparable across parameters with different units.
  • The 95% columns are credible intervals: the range containing the middle 95% of the posterior draws, so there is a 95% probability the parameter lies within it, given the model, priors, and data.
  • I compute the ratio \(V_{\max}/K_m\) from the same draws, so it has its own posterior.

Model 1 interpretation: The two kinetic parameters mean different things:

  • \(V_{\max}\) is the reaction’s top speed, reached when substrate is plentiful and every enzyme molecule is busy.
  • \(K_m\) is the substrate concentration at which the rate is half of \(V_{\max}\). It marks where “low” substrate ends and “high” substrate begins.

Both are poorly determined here. Relative SD is 34% and 37%, and the 95% intervals are wide: \(V_{\max}\) could be anywhere from 49 to 169 µM/hour and \(K_m\) from 10 to 37 µM. Their ratio is known to within 4%. I believe this is due to the model structure, not the sampler. Models 1-4 use only \(C_{A0}=3.125\) µM, so the substrate never gets near \(K_m\), and the rate is roughly \((V_{\max}/K_m) C_A\) throughout; the curve reveals only the ratio, not the two parameters separately.

Initial substrate (µM) \(R^2\)
3.125 0.9638

Fit: \(R^2\) compares the squared error of the fitted curve to the squared spread of the data around their own mean:

\[ R^2 = 1 - \frac{\sum_i (y_i - \hat y_i)^2}{\sum_i (y_i - \bar y)^2} \]

I am assuming that the article’s fits were done with MATLAB’s fit and fitlm functions, so I used the same definition as the MATLAB Curve Fitting Toolbox (Evaluating Goodness of Fit), with the posterior mean of \(\mu\) as the fitted curve. A value of 1 means the curve passes through every point, and 0 means it does no better than a flat line at the mean. For models 1-4, there is only one concentration, so the table has one row.

Model 1 interpretation: This \(R^2\) is computed from:

  • \(y_i\): the 115 measured product concentrations in the 3.125 µM curve, including the first ten minutes (Model 1 keeps the full series)
  • \(\hat y_i\): the posterior mean of \(\mu\) at each measured time, which is the dark blue line in the posterior predictive plot
  • \(\bar y\): the mean of the 115 measurements

\(R^2=0.964\) sounds high, but for a simple, predictable curve it is not that impressive, and concentration \(R^2\) is a weak measure anyway. Model 5 reaches 0.999948, yet when its parameters are used in the integrated equation to predict time, the \(R^2\) drops to 0.28 overall and to 0.18 for the \(C_{A0}=3.125\) µM curve, before any adjustments. If an almost perfect concentration fit yields poor time predictions, 0.964 is somewhat concerning.

6.3 Model 1 Plots

Prior predictive check: Before fitting, I checked what the priors allow. Each gray line is one curve the model considers plausible, so the observations should fall within the range the lines cover.

Model 1 interpretation: The guesses were too slow and too low. \(V_{\max}\sim\operatorname{LogNormal}(0,1)\) has a median of \(e^0=1\) µM/hour, two orders of magnitude below the article’s \(V=109\) µM/hour, so the curves climb much too slowly. With \(C_{B0}\) fixed and no offset \(b\), they all start at zero. The right panel only covers the points because \(\sigma\) allows a lot of noise. Even so, the data still mostly pulled the model toward the right answer.

Residuals: Residuals are the observed values minus the fitted curve. In linear regression, you should see a random scatter around zero. A pattern here suggests the model’s assumptions are missing something.

Model 1 interpretation: The residuals are not random, and the plot points to two causes. The first readings sit well above zero because the model is forced to start at \(C_{B0}=0\) while the first measurement is already about 0.45 µM. The plateau sits about 0.12 µM below zero because the model must level off at exactly \(C_{A0}=3.125\) µM while the data level off near 3.0 µM. Models 2–4 address these by dropping the first ten minutes, estimating \(C_{B0}\), and adding an offset \(b\).

Posterior predictive check: After fitting, the plot shows:

  • The dark line is the posterior mean of \(\mu_i\)
  • The blue band is the 95% credible interval of \(y_i\sim\operatorname{Normal}(\mu_i,\sigma)\), the likelihood from the earlier table, evaluated over all posterior draws of \(V_{\max}\), \(K_m\), and \(\sigma\). It is where the model expects new measurements to fall, so it is wider than the uncertainty in \(\mu_i\) alone.
  • The subtitle reports \(R^2\)

(Again, 95% is a preference. Any other level would be just as valid.)

Model 1 interpretation: The band covers every observation, but only because it is wide. \(\sigma\) came out at 0.117 µM, roughly ten times what Model 4 finds on the same curve, so the model absorbed its misfit into the noise instead of the curve. \(R^2=0.964\) is the lowest of the six models.

Parameter distributions: Each panel overlays the prior (orange) and the posterior (blue) for one parameter, with dashed lines at the posterior’s 95% interval. Three things to look for:

  • How much narrower the posterior is than the prior, which shows how much the data taught the model
  • Where the posterior sits relative to the prior, which shows whether the prior was centered in the right place
  • How many peaks the posterior has, since more than one means the data support several different answers

Model 1 interpretation: To start, all three posteriors have one peak. And the posteriors for \(V_{\max}\) and \(K_m\) are much narrower than their priors but still wide, and both sit far to the right of the prior peak. The ratio \(V_{\max}/K_m\) is sharp and narrow, which is the only quantity this model pins down.

6.4 Differences in the models

Model 1 is the baseline. Its assumptions are:

  • One experiment, \(C_{A0}=3.125\) µM, fixed
  • Full time series, including the first ten minutes
  • Michaelis–Menten rate law
  • \(C_{B0}=0\), fixed
  • No measurement offset
  • Priors: \(V_{\max},K_m\sim\operatorname{LogNormal}(0,1)\), \(\sigma\sim\operatorname{HalfNormal}(1)\)
  • Likelihood: \(y_i\sim\operatorname{Normal}(\mu_i,\sigma)\)

Each later model changes the previous one as follows. Anything not listed is unchanged.

Model Change from the previous model Reason
2
  • First ten minutes excluded
  • Time re-zeroed at the first retained reading
  • \(C_{B0}\) fixed at that reading, which is then dropped from the fitted data
  • The article identifies the first ten minutes as a stabilization period
  • Model 1’s residuals were largest there
3
  • Offset \(b\sim\operatorname{Normal}(0,1)\) added to \(\mu_i\)
  • The first retained reading is kept in the fitted data
  • Model 1’s residuals plateau below zero, so the measurements are shifted relative to the curve
4
  • \(C_{B0}\) estimated, \(C_{B0}\sim\operatorname{Uniform}(0,C_{A0})\), instead of fixed
  • Fixing \(C_{B0}\) to a single noisy reading forces the curve through that point
5
  • All five experiments fitted together (\(C_{A0}\) = 3.125 to 50 µM)
  • \(V_{\max}\), \(K_m\), and \(\sigma\) shared across experiments
  • \(C_{B0}\) and \(b\) estimated separately for each experiment
  • A single low-concentration curve only identifies \(V_{\max}/K_m\)
  • Higher concentrations are needed to separate them
6
  • Michaelis–Menten replaced by the Hill equation
  • Exponent \(h\sim\operatorname{LogNormal}(0,0.5)\). \(h=1\) recovers Model 5
  • Tests whether the rate law itself is adequate

7 Model 5: Fitting All Concentrations Together

7.1 Model 5 Tables

Parameter ESS bulk ESS tail R̂
\(V_{\max}\) 1490 1946 1.003
\(K_m\) 1506 2006 1.002
\(C_{B0}\) [3.125] 4009 3184 1.001
\(C_{B0}\) [6.25] 3470 3227 1.002
\(C_{B0}\) [12.5] 3197 2966 1.001
\(C_{B0}\) [25] 3514 3017 1.001
\(C_{B0}\) [50] 1801 2350 1.003
\(b\) [3.125] 3652 3052 1.000
\(b\) [6.25] 3482 2989 1.000
\(b\) [12.5] 3289 2807 1.001
\(b\) [25] 3218 2970 1.000
\(b\) [50] 2782 2912 1.002
\(\sigma\) 4370 3150 1.002

Divergences: 0

Model 5 interpretation: Every ESS is above 1,400, every \(\hat R\) is 1.003 or below, and there are no divergences. The sampler handled the thirteen-parameter joint model without difficulty.

Parameter Mean SD Relative SD (%) 95% lower 95% upper
\(V_{\max}\) (µM/hour) 118.93 1.30 1.1 116.43 121.45
\(K_m\) (µM) 23.07 0.42 1.8 22.25 23.86
\(V_{\max}/K_m\) (1/hour) 5.16 0.04 0.8 5.08 5.23
\(C_{B0}\) [3.125] (µM) 1.856 0.053 2.8 1.754 1.961
\(C_{B0}\) [6.25] (µM) 3.364 0.049 1.5 3.267 3.461
\(C_{B0}\) [12.5] (µM) 5.672 0.049 0.9 5.574 5.765
\(C_{B0}\) [25] (µM) 9.358 0.043 0.5 9.271 9.442
\(C_{B0}\) [50] (µM) 13.080 0.056 0.4 12.972 13.195
\(b\) [3.125] (µM) -0.117 0.013 11.4 -0.142 -0.090
\(b\) [6.25] (µM) 0.086 0.013 15.3 0.061 0.113
\(b\) [12.5] (µM) 0.369 0.014 3.7 0.342 0.396
\(b\) [25] (µM) 1.738 0.015 0.9 1.709 1.769
\(b\) [50] (µM) 2.722 0.019 0.7 2.686 2.760
\(\sigma\) (µM) 0.118 0.004 3.0 0.112 0.125

Model 5 interpretation:

  • Fitting the five curves together separates \(V_{\max}\) and \(K_m\). Their relative SD drops from 34% and 37% in Model 1 to 1.1% and 1.8%, and the intervals are now a few µM wide instead of tens.
  • The values are close to the article’s \(V=109\) µM/hour and \(K_m=21.5\) µM, within 9% and 7%, though neither article value falls inside the 95% interval.
  • The per-experiment offsets \(b\) range from -0.1 to 2.7 µM, so sharing one would not have worked. \(\sigma\) stays at 0.118 µM because the high-concentration curves have more scatter in absolute terms.
Initial substrate (µM) \(R^2\)
3.125 0.99834
6.25 0.99832
12.5 0.99487
25 0.99899
50 0.99963
All 0.99995

Model 5 interpretation: The overall \(R^2\) is higher than any single curve’s because each \(C_{A0}\)’s \(R^2\) is judged against that group’s own small spread, which magnifies its error. In contrast, the aggregated \(R^2\) is judged against the full 2-50 µM range. The per-curve values are the honest ones, and all five are above 0.994. The 12.5 µM curve fits least well.

7.2 Model 5 Plots

Posterior predictive check: Same plot as Model 1, one row per experiment. The right panel of each row zooms into 0.4 to 0.6 hours. The vertical span of the zoom is set by the 3.125 µM curve and reused for all five, so you can compare bandwidth across concentrations at the same scale.

Model 5 interpretation: The band has roughly the same width for every curve because all five share the same \(\sigma\) of 0.118 µM. That width is a large fraction of the 3.125 µM curve and a negligible fraction of the 50 µM curve, so the zoom uses a common vertical span.

Residual plot: Measured minus predicted product at every time point, one row per experiment. The left column is in µM on a shared scale. The right column divides each residual by that experiment’s initial substrate, so the five curves can be judged on equal footing.

Model 5 interpretation:

  • In µM, the low curves look clean and the high ones noisy, so the noise grows with concentration. The model assumes one fixed \(\sigma\) for all five, which is slightly off. The scaled column corrects for this, and there all five look alike.
  • Subtle waves remain, most visibly in the middle concentration, where the model runs slightly high early and slightly low later. A wave like that means the curve bends a little differently from what Michaelis–Menten predicts, which is the mismatch Model 6 is meant to test.
  • All five curves drift slightly below zero at late times, when measurements are farther apart, and the reaction nears its plateau. The model predicts a bit more product than was measured at the end.
  • Compared with Model 1, which left a clear pattern on its single curve, these residuals sit much closer to noise around zero.

Model 5 interpretation: All three posteriors are single narrow peaks far to the right of the priors. Unlike Model 1, \(V_{\max}\) and \(K_m\) are now each as sharp as their ratio.

8 Model 6: Generalizing to the Hill Equation

Model 6 introduces the Hill exponent \(h\):

\[ \frac{dC_B}{dt} = \frac{V_{\max}C_A^h}{K_{0.5}^h+C_A^h} \]

When \(h=1\), this reduces to Michaelis–Menten kinetics. Varying \(h\) changes the shape of the rate response to substrate concentration.

For convenience and consistency, I kept the name \(K_m\) in the code and the tables, but in the Hill equation this constant is called \(K_{0.5}\). Both are the substrate concentration at half the limiting rate. The difference is in how to interpret them physically. \(K_m\) comes from a specific mechanism, while \(K_{0.5}\) does not, but this distinction doesn’t affect the Bayesian analysis.

I assigned \(h\) a lognormal prior with a median of one, so the model starts from Michaelis–Menten and lets the data move away from it, as \(V_{\max}\) and \(K_m\) are estimated rather than fixed.

8.1 Model 6 Tables

Parameter ESS bulk ESS tail R̂
\(V_{\max}\) 137 154 1.036
\(K_m\) 137 156 1.037
\(h\) 143 144 1.033
\(C_{B0}\) [3.125] 123 185 1.057
\(C_{B0}\) [6.25] 342 278 1.043
\(C_{B0}\) [12.5] 587 304 1.011
\(C_{B0}\) [25] 478 408 1.004
\(C_{B0}\) [50] 290 241 1.014
\(b\) [3.125] 342 216 1.011
\(b\) [6.25] 532 393 1.001
\(b\) [12.5] 579 354 1.005
\(b\) [25] 503 316 1.004
\(b\) [50] 822 345 1.010
\(\sigma\) 233 251 1.012

Divergences: 0

Model 6 interpretation: This run does not pass. The three kinetic parameters have ESS near 140 (well under 400), and \(\hat R\) is between 1.03 and 1.06 for several parameters, above the 1.01 warning level. The cause was computation. I started with the nutpie sampler for speed, but Model 5 crashed under it more than once, so I switched to PyMC’s NUTS sampler and reran Models 1 to 5 on it. Model 6 still wouldn’t cooperate: at 1,000 draws, memory climbed past 34 GB a quarter of the way through, and the process crashed, so I sampled it with 100 draws and 100 tuning steps per chain instead. The likely bottleneck is PyMC’s ODE solver, which runs on a SciPy backend. The docs suggest a faster alternative, but that is a separate project I chose not to take on.

Which means the estimates are sketchy. The means are probably in the right place, but you shouldn’t trust the intervals.

So if you plan on sampling model 6 yourself, expect trouble.

Parameter Mean SD Relative SD (%) 95% lower 95% upper
\(V_{\max}\) (µM/hour) 146.34 5.07 3.5 136.96 157.51
\(K_m\) (µM) 34.58 2.29 6.6 30.45 39.66
\(V_{\max}/K_m\) (1/hour) 4.24 0.13 3.1 3.97 4.49
\(h\) 0.920 0.010 1.1 0.900 0.940
\(C_{B0}\) [3.125] (µM) 1.818 0.050 2.7 1.729 1.920
\(C_{B0}\) [6.25] (µM) 3.337 0.049 1.5 3.246 3.428
\(C_{B0}\) [12.5] (µM) 5.695 0.051 0.9 5.597 5.794
\(C_{B0}\) [25] (µM) 9.461 0.040 0.4 9.391 9.537
\(C_{B0}\) [50] (µM) 12.946 0.055 0.4 12.835 13.049
\(b\) [3.125] (µM) -0.132 0.013 10.0 -0.159 -0.105
\(b\) [6.25] (µM) 0.062 0.013 21.1 0.036 0.087
\(b\) [12.5] (µM) 0.337 0.014 4.0 0.312 0.364
\(b\) [25] (µM) 1.710 0.013 0.8 1.685 1.736
\(b\) [50] (µM) 2.697 0.017 0.6 2.664 2.728
\(\sigma\) (µM) 0.113 0.003 3.1 0.106 0.119

Model 6 interpretation:

  • \(h\) comes out at 0.92, with an interval of 0.90 to 0.94 that excludes 1. This suggests that the data prefer a slightly flatter rate response than Michaelis–Menten. However, due to sampling difficulties, we cannot be sure this inference is robust.
  • In addition, letting \(h\) move pulls \(V_{\max}\) and \(K_m\) up to 146 µM/hour and 35 µM, further from the article’s 109 and 21.5 than Model 5’s values. This is expected: with \(h<1\), the rate approaches \(V_{\max}\) more slowly, so the fit compensates with a higher ceiling and a higher half-saturation point.
  • The per-experiment \(C_{B0}\), \(b\), and \(\sigma\) are almost identical to Model 5. The extra parameter changes the kinetics, not the measurement model.
Initial substrate (µM) \(R^2\)
3.125 0.99311
6.25 0.99810
12.5 0.99360
25 0.99925
50 0.99969
All 0.99995

Model 6 interpretation: The overall \(R^2\) is 0.999953, compared with Model 5’s 0.999948, a difference in the fifth decimal place. Per curve, Model 6 is slightly better at 25 and 50 µM and slightly worse at 3.125, 6.25, and 12.5 µM. The extra parameter essentially improves nothing over model 5 at this stage.

8.2 Model 6 Plot

Model 6 interpretation: The \(h\) panel is the one to look at. The prior is centered at 1 and the posterior sits just below it, narrow and clearly shifted. \(V_{\max}/K_m\) looks like Model 5’s, but \(V_{\max}\) and \(K_m\) are each noticeably wider, with relative SD of 3.5% and 6.6% against 1.1% and 1.8%. Adding \(h\) lets the three kinetic parameters trade off, so each is less constrained. The sampling problems make these widths less trustworthy, but the extra parameter is expected to widen them.

9 Using Models 5 and 6 to Estimate Time

9.1 Integrated Michaelis–Menten and Hill Equations

After fitting the concentration curves, I used the integrated equations to estimate the time required to reach a specified product concentration.

Here, \(C_{A0}\) is the initial substrate concentration before the reaction began, while \(C_{B0}\) is the product concentration at the shifted time origin. Consistent with the implemented models:

\[ C_A(t)=C_{A0}-C_B(t), \qquad C_A(0)=C_{A0}-C_{B0} \]

Thus, the substrate remaining at the shifted starting time is \(C_{A0}-C_{B0}\), rather than \(C_{A0}\) itself. This distinction connects the earlier derivation to the initial conditions used in the models.

For Michaelis–Menten kinetics:

\[ t= \frac{ C_B-C_{B0} -K_m\ln\left(\frac{C_{A0}-C_B}{C_{A0}-C_{B0}}\right) }{V_{\max}} \]

For the Hill model, when \(h\ne1\):

\[ t= \frac{1}{V_{\max}} \left[ C_B-C_{B0} + \frac{K_m^h}{h-1} \left( (C_{A0}-C_B)^{1-h} - (C_{A0}-C_{B0})^{1-h} \right) \right] \]

The limit as \(h\) approaches one gives the Michaelis–Menten expression. These calculations use posterior mean parameter values, so they produce point estimates rather than a full distribution of predicted times.

9.2 Correcting Measured Concentrations for the Offset

The integrated equations give \(t(C_B)\), the time at which the true product concentration reaches \(C_B\). The observations are not \(C_B\) directly. From the likelihood, each reading is

\[ y_i \sim \operatorname{Normal}(\mu_i, \sigma), \qquad \mu_i = C_B(t_i) + b \]

So \(y\) is the true product plus the offset plus measurement noise. The quantity I actually evaluate is

\[ \hat t = t(y - \hat b) \]

with \(\hat b\) the posterior mean offset for that experiment. This removes the estimated constant shift but not the noise, so the corrected measurements can still fall outside the kinetic model’s physical range. ## Comparing Predicted and Recorded Times

For each corrected measurement, I calculated a predicted time \(\hat t = t(y - \hat b)\) and compared it with the recorded time on the shifted time axis.

Model 5

Model 6

Time prediction plot:

  • Points are the corrected measurements at their recorded times.
  • Lines are the same measurements at their predicted times.
  • If the integrated equation were exact, every point would sit on its line.
  • The number at the end of each curve is its final corrected measurement.

I defined the time residual as:

\[ r_t=t_{\mathrm{recorded}}-\hat t \]

The time-based coefficient of determination was calculated as:

\[ R_t^2= 1- \frac{ \sum_j(t_j-\hat t_j)^2 }{ \sum_j(t_j-\bar t)^2 } \]

This measures agreement in time, rather than concentration. Because I also used the observations to fit the models, this is an in-sample consistency check, not an independent validation of future predictions. Measurements whose corrected concentration reached or exceeded \(C_{A0}\) give an infinite or undefined \(\hat t\) and are excluded from \(R_t^2\).

\(C_{A0}\) (µM) Rows used (5) \(R_t^2\) (5) Rows used (6) \(R_t^2\) (6)
3.125 84 0.185 56 0.268
6.25 89 0.136 69 0.144
12.5 71 0.319 64 0.346
25 87 0.285 85 0.261
50 101 0.492 101 0.473
All 432 0.283 375 0.311

Models 5 and 6 interpretation: The time predictions are horrific for both models, with \(R_t^2\) between 0.14 and 0.49 per curve and 0.28 and 0.31 overall, despite concentration \(R^2\) above 0.9999. Neither model is clearly better. Model 6 loses more rows to infinite predictions (375 kept vs. 432) because its offsets are slightly smaller, leaving more corrected values above \(C_{A0}\). The plots show where the damage is: the lines and points agree early in each curve and come apart as the curve flattens. The next section looks at why.

10 Investigating Errors Near the Plateau

10.1 Why Small Concentration Errors Become Large Time Errors

Sensitivity plot: This shows how a small error in the measured product concentration turns into an error in the predicted time.

  • The blue curve is \(t(C_B)\), the predicted time to reach a given product concentration, from the integrated Michaelis–Menten equation with Model 5’s posterior means for the 3.125 µM experiment.
  • The dashed line is \(C_{A0}\). The curve goes vertical there because the predicted time is infinite when all the substrate is gone.
  • Each black point is a true concentration and its true time on the curve.
  • The green segment below a point shows how much earlier the predicted time would be if the measurement read \(\sigma\) as \(0.118\) µM too low.
  • The red segment above a point shows how much later the prediction would be if the measurement read \(\sigma\) too high.

Model 5 interpretation: At the first point, the two segments are nearly equal. For the second point, the red segment (0.53 h) is four times the green one (0.13 h), because the logarithm grows without bound as \(C_B\) approaches \(C_{A0}\). Reading slightly high near the plateau is far worse than reading slightly low because the curve bends upward toward the asymptote, and the closer the measurement is to \(C_{A0}\), the worse it gets. Measurements near the plateau cannot give usable time predictions no matter how good the concentration fit is.

Model 5 posterior means for the \(3.125\,\mu\mathrm{M}\) experiment:

\[ V_{\max}=118.93,\qquad K_m=23.07,\qquad C_{B0}=1.856,\qquad C_{A0}=3.125,\qquad \sigma=0.118 \]

Integrated Michaelis–Menten equation (the blue curve):

\[ t(C_B)= \frac{ C_B-C_{B0} -K_m\ln\left(\dfrac{C_{A0}-C_B}{C_{A0}-C_{B0}}\right) }{V_{\max}} \]

Each black point is placed at a fraction \(f\) of the way from \(C_{B0}\) to \(C_{A0}\):

\[ C_B = C_{B0} + f\,(C_{A0}-C_{B0}) \]

The green segment runs from \(t(C_B-\sigma)\) up to \(t(C_B)\). The red segment runs from \(t(C_B)\) up to \(t(C_B+\sigma)\).

First point

\[ \begin{alignedat}{2} C_B &= 1.856+0.6\,(3.125-1.856)=2.617 &&\quad (f=0.6) \\[6pt] t(2.617) &= 0.184\ \text{h} &&\quad (\text{Black point}) \\[6pt] t(2.617-0.118) &= t(2.499)=0.143\ \text{h} &&\quad (\text{Bottom of green segment}) \\[6pt] 0.184-0.143 &= 0.04\ \text{h} &&\quad (\text{Green segment length}) \\[6pt] t(2.617+0.118) &= t(2.735)=0.236\ \text{h} &&\quad (\text{Top of red segment}) \\[6pt] 0.236-0.184 &= 0.05\ \text{h} &&\quad (\text{Red segment length}) \end{alignedat} \]

Second point

\[ \begin{alignedat}{2} C_B &= 1.856+0.9\,(3.125-1.856)=2.998 &&\quad (f=0.9) \\[6pt] t(2.998) &= 0.456\ \text{h} &&\quad (\text{Black point}) \\[6pt] t(2.998-0.118) &= t(2.880)=0.328\ \text{h} &&\quad (\text{Bottom of green segment}) \\[6pt] 0.456-0.328 &= 0.13\ \text{h} &&\quad (\text{Green segment length}) \\[6pt] t(2.998+0.118) &= t(3.116)=0.973\ \text{h} &&\quad (\text{Top of red segment}) \\[6pt] 0.973-0.456 &= 0.52\ \text{h} &&\quad (\text{Red segment length}) \end{alignedat} \]

At the first point, the two segments are nearly equal. At the second point, the red segment (0.52 h) is four times the green one (0.13 h) because the logarithm grows without bound as \(C_B\) approaches \(C_{A0}\). The plot shows 0.53 h because it uses the unrounded posterior means. The rounded values here give 0.52 h.

10.2 Residuals and Rates of Concentration Change

To investigate where the large errors occurred, I added three columns to each time-analysis row: the time residual, the percentage change in corrected product concentration between consecutive measurements, and that change per hour.

\[ \begin{alignedat}{2} r_{t,j} &= t_{\mathrm{recorded},j}-\hat t_j &&\quad (\text{Time residual}) \\[8pt] \Delta_j &= 100\,\frac{C_{B,j}-C_{B,j-1}}{C_{B,j-1}} &&\quad (\text{Concentration change, \%}) \\[8pt] \rho_j &= \frac{\Delta_j}{t_{\mathrm{recorded},j}-t_{\mathrm{recorded},j-1}} &&\quad (\text{Concentration change, \% per hour}) \end{alignedat} \]

Dividing by the elapsed time accounts for differences in measurement spacing and helps identify where concentration is changing slowly. The denominator of \(\Delta_j\) is the previous product concentration, so it is a relative change in product, not a percentage of the initial substrate concentration.

Row Recorded \(t\) (h) \(C_B\) (µM) \(\hat t\) (h) \(r_t\) (h) \(\Delta\) (%) \(\rho\) (%/h)
0 0.000 1.874 0.003 -0.003
1 0.017 1.955 0.016 0.000 4.31 258.6
2 0.033 2.059 0.036 -0.002 5.34 320.5
3 0.050 2.136 0.051 -0.001 3.70 222.1
⋮
30 0.500 3.019 0.491 0.009 0.41 24.3
31 0.517 3.039 0.533 -0.016 0.68 40.9
32 0.533 3.031 0.515 0.018 -0.28 -16.5
⋮
36 0.600 3.073 0.630 -0.030 0.40 23.5
37 0.617 3.073 0.630 -0.013 0.00 0.0
38 0.634 3.078 0.648 -0.014 0.15 8.9
39 0.650 3.077 0.645 0.006 -0.02 -1.5
⋮
60 1.000 3.132 undefined undefined 0.07 4.4
61 1.017 3.128 undefined undefined -0.15 -8.8
⋮
104 3.334 3.105 0.816 2.518 -0.17 -2.1

Model 5 interpretation:

  • Up to about row 36 (0.6 hours), the predictions are good: residuals are hundredths of an hour or less, and the concentration is still changing quickly.
  • From row 37 onward, they are not: \(C_B\) sits within 0.05 µM of \(C_{A0}\), the concentration change flips sign as noise takes over, \(\hat t\) becomes undefined wherever \(C_B\) crosses 3.125 µM, and the final row has a 2.5-hour residual

10.3 Defining the Plateau Cutoff

I removed points using two rules on \(\rho\), the percentage change per hour:

  • \(|\rho|\) has to be at or below 10.
  • It has to happen on two consecutive readings.

When both conditions are met, I removed the first of those two readings and every subsequent reading from that experiment’s time-analysis subset. A cutoff of 10 means a relative concentration change of at most 10% per hour, not a 10% difference between observations.

This is the most subjective part of the project. I tried different combinations of the threshold and the number of consecutive readings, eyeballed the cut plots, and picked the pair that looked best while keeping the most rows. It is not perfect, but the other combinations did not change the results too much either.

The cutoff did not change the data used to fit the Bayesian models. The original data were preserved, and the cutoff created a separate dataframe for evaluating the inverse time calculation.

10.4 Results Before and After the Cutoff

After applying the cutoff, I recalculated the time-based \(R^2\) using finite predictions and recorded how many observations remained in each group.

\(C_{A0}\) (µM) Retained Removed Total
3.125 37 68 105
6.25 36 69 105
12.5 40 65 105
25 49 56 105
50 60 45 105

The counts are identical for Models 5 and 6.

\(C_{A0}\) (µM) Full (5) Cut (5) Full (6) Cut (6)
3.125 0.185 0.997 0.268 0.965
6.25 0.136 0.998 0.144 0.993
12.5 0.319 0.984 0.346 0.974
25 0.285 0.997 0.261 0.999
50 0.492 0.997 0.473 0.998
All 0.283 0.996 0.311 0.992

Model 5

Model 6

Models 5 and 6 interpretation:

  • Even the curve that lost the least still had 43% of its readings removed, and the curve that lost the most had 66% removed. Both models lose the same rows.
  • Lower \(C_{A0}\) concentrations lose more because they reach the plateau sooner.
  • On what remains, the overall \(R_t^2\) jumps from about 0.3 to 0.996 for Model 5 and 0.992 for Model 6, and every individual curve is above 0.96. Model 5 is now slightly better on four of five curves.
  • This does not mean that the predictions improved. The calculation excludes the region where the inverse equation is most sensitive.

11 Evaluating the Cutoff Decision

11.1 Retained Observations and Final Concentration Differences

To see what the cutoff actually costs the model, I compared the last corrected product concentration in each full curve with the last one kept after the cutoff.

For each group, I calculated:

\[ \text{Absolute difference} = \left| C_{B,\mathrm{full,last}} - C_{B,\mathrm{cut,last}} \right| \]

and:

\[ \text{Percentage difference} = 100\frac{ \left| C_{B,\mathrm{full,last}} - C_{B,\mathrm{cut,last}} \right| }{ \left|C_{B,\mathrm{full,last}}\right| } \]

These values show how much the observed endpoint changes when we exclude the late measurements. They compare the last readings, which may not be the largest because of measurement noise.

Model \(C_{A0}\) (µM) Full last \(C_B\) (µM) Cut last \(C_B\) (µM) Absolute difference (µM) Difference (%)
5 3.125 3.105 3.073 0.032 1.03
5 6.25 6.203 6.104 0.099 1.60
5 12.5 12.457 12.155 0.302 2.42
5 25 24.775 24.622 0.153 0.62
5 50 49.610 49.201 0.409 0.82
6 3.125 3.121 3.089 0.032 1.03
6 6.25 6.228 6.129 0.099 1.59
6 12.5 12.489 12.187 0.302 2.42
6 25 24.804 24.651 0.153 0.62
6 50 49.636 49.226 0.409 0.82

Models 5 and 6 interpretation:

  • Removing 43% to 66% of each curve moves the final concentration by at most 2.4%, and under 1% for the two highest concentrations.
  • The absolute differences are identical between the models because both cut at the same rows and the offset cancels in the subtraction. Only the percentages differ, and only in the third decimal.
  • The 12.5 µM curve is the outlier at 2.4%. It also has the lowest concentration \(R^2\) in both models.

11.2 Comparing Both Models on the Same Observations

The model-specific offsets can produce different corrected concentrations and cutoff locations. Comparing Models 5 and 6 only on their separately retained subsets could therefore favor a model partly because it was evaluated on different observations.

So I also compared them on the observations both models kept, matched by concentration and recorded time, using only finite predictions.

Model Matched rows \(R_t^2\)
5 222 0.996
6 222 0.992

Models 5 and 6 interpretation: The concern didn’t matter here. Both models cut every curve at the same row, so the matched subset is the full cut subset and the matched \(R_t^2\) equals the cut \(R_t^2\) from the previous section. On identical observations, Model 5 is slightly better.

11.3 Use Case: Picking a Starting Concentration for a Target

Say you want to reach 10 µM of product and can start from 12.5, 25, or 50 µM. The prediction works only if the target falls within the part of the curve the cutoff kept.

  • 50 µM: hits 10 µM during the first ten minutes, before the reaction has stabilized. The models were not fitted to that period, so there is nothing to predict from.
  • 25 µM: hits it less than a minute into the usable data. Technically inside, but barely.
  • 12.5 µM: hits it at about 14 minutes, comfortably inside the kept region, with an uncertainty of about half a minute.

Starting high is fast but can blow past the target before you can see it. Starting low is slow but gives you a measurable window, at the cost of being closer to the plateau. Choose based on whether speed or resolution matters more, and first check that the target falls within the kept region.

12 Conclusions and Limitations

12.1 What the Project Demonstrated

This project fitted Michaelis–Menten kinetics to enzyme progress curves with Bayesian inference, testing how initial conditions, measurement offsets, and shared parameters affect the result.

Model 5 fits all five substrate concentrations, with \(V_{\max}\) and \(K_m\) each determined within 2% and within about 9% of the article’s independently fitted values. The Hill extension in Model 6 did not improve the fit and could not be sampled properly on my hardware, so Model 5 is the clear winner of the six.

12.2 Were the Project Goals Achieved?

What are the Michaelis–Menten parameters, and how uncertain are they? Yes. Model 5 gives \(V_{\max} = 118.9 \pm 1.3\) µM/hour and \(K_m = 23.1 \pm 0.4\) µM, with full posteriors rather than point estimates, and the values sit within about 9% of the article’s.

Can those parameters predict the time to reach a target concentration? Partly. The prediction is reliable while the reaction is still moving, but it breaks down near the plateau, where ordinary measurement noise turns into hours of time error. So the answer is yes for targets before the plateau, and no for targets close to \(C_{A0}\). The practical workaround is to choose a starting concentration that puts the target in the usable window.

12.3 What Still Requires Validation

I checked everything against the same data the models were fitted to. Whether the models hold up in new experiments, how much the priors matter, and whether a constant offset and independent noise are good enough assumptions remain open questions.

The time predictions use single best-guess parameter values. Running the full posterior through the time equation instead would give each prediction an uncertainty range.

I tuned the plateau cutoff using these data, so the improved \(R^2\) after cutting partly reflects that tuning. It should be tested on data it was not designed around.

12.4 Bayesian Statistics in Other Fields

Nothing here is specific to enzymes. The same workflow applies wherever a field already has a trusted model and noisy data to fit it to:

  • Pharmacokinetics
  • Epidemiology
  • Chemical and process engineering
  • Economics and finance
  • Ecology
  • Physics and astronomy
  • Sports analytics

The payoff is the same in each case. You get a distribution for each parameter instead of a point estimate, and the diagnostics tell you when the sampler or model is failing, while the predictive checks show where the model’s assumptions stop holding, as the plateau did here.

Thumbnail icon from Magnific from Flaticon

Thumbnail icon from Magnific from Flaticon