Tutorials › Bayesian Clinical Trials › Proper Priors and Parameter Support

Choosing and Eliciting Priors · Tutorial 36 of 696

Proper Priors and Parameter Support

Distinguish proper and improper priors, match prior support to clinical-trial parameters, and check when the data produce a valid posterior.

Intermediate 10 min read

What You'll Learn

  • Define proper and improper priors and distinguish prior propriety from posterior propriety.
  • Check that a prior assigns mass only to valid values of a trial parameter.
  • Derive when a flat prior for an event rate gives a proper posterior.
  • Recognize how zero exposure can make a likelihood identically zero or constant.
  • Use a prior on log hazard ratio to enforce positive hazard-ratio values.
  • Diagnose support mismatches and compare proper priors with improper alternatives.

Why Propriety and Support Matter

A prior does two distinct jobs in a Bayesian clinical-trial model. It represents uncertainty about an unknown parameter before the trial data are incorporated, and it specifies which parameter values are possible under the model. Both jobs require care. A prior may put mass on impossible values, or it may fail to define a probability distribution at all. Even if an improper prior is used as a formal starting point, the resulting posterior must have a finite, positive normalizing constant before it can be interpreted as a probability distribution.

For example, an event probability \(p\) must lie between zero and one, and an event rate \(\lambda\) must be positive. A hazard ratio must also be positive, whereas its logarithm can take any real value. A treatment-effect parameter therefore needs a support compatible with its definition. Support is not the same as plausibility: a prior can allow only valid values yet still place too much probability on values considered clinically implausible.

Definition: A proper prior is a probability distribution whose total probability is one. For a continuous parameter \(\theta\) with density \(\pi(\theta)\), this requires \(\int_{\Theta}\pi(\theta)\,d\theta=1\). For a discrete parameter, the probabilities over its possible values must sum to one. An improper prior is a nonnegative measure or density that cannot be normalized to total probability one. The support of a prior on the usual Euclidean parameter space is the set of points every open neighborhood in the parameter space of which has positive prior probability (equivalently, the smallest closed set having prior probability one); for a discrete prior, this includes every positive-mass point and may also include limit points of such points.

In continuous models, a density value is not itself a probability: probabilities are obtained by integrating the density over sets. A density can be positive throughout a valid parameter range while still having an infinite integral. For example, the constant density kernel \(\pi(\lambda)\propto 1\) over \(0<\lambda<\infty\) has infinite integral and is therefore improper. It is often called a flat prior on that range, but it is not a probability distribution.

Posterior Propriety: The Normalizing-Integral Check

Bayes' rule combines a likelihood \(L(\theta;y)\) for observed data \(y\) with a prior. When the prior is proper, the posterior density is proportional to \(L(\theta;y)\pi(\theta)\). When an improper prior is used, its arbitrary multiplicative constant cancels in the posterior formula, but cancellation alone does not ensure a valid posterior. In either case, the normalizing integral must be finite and strictly positive.

$$ Z(y)=\int_{\Theta} L(\theta;y)\pi(\theta)\,d\theta, \qquad \pi(\theta\mid y)=\frac{L(\theta;y)\pi(\theta)}{Z(y)} $$

Here \(Z(y)\) is the marginal likelihood when \(\pi\) is a proper prior. With an improper prior, the same integral is a normalizing integral, but it is not a marginal probability for the data. A posterior exists as a probability distribution only when \(0<Z(y)<\infty\). If \(Z(y)=\infty\), the proposed posterior cannot be normalized. If \(Z(y)=0\), the likelihood is zero for prior-almost-every parameter value, so Bayes' rule also cannot produce a posterior.

A useful sufficient condition is that the prior is proper, the likelihood is bounded above as a function of the parameter, and the likelihood is positive on a set having positive prior probability. Then the integral is finite and positive. The boundedness and positivity conditions matter: propriety of the prior alone is not a universal guarantee for every possible likelihood and dataset.

Worked Example: A Proper Beta Prior for an Event Probability

Suppose a hypothetical trial observes \(y=4\) events among \(n=10\) participants, with conditionally independent Bernoulli outcomes having common event probability \(p\). Let the prior be \(p\sim\operatorname{Beta}(2,3)\). The parameter support is \(0<p<1\), which is valid for an event probability, and the prior is proper because its beta density integrates to one.

The likelihood, omitting a factor that does not depend on \(p\), is \(p^4(1-p)^6\). The prior density is proportional to \(p^{2-1}(1-p)^{3-1}\). Multiplying these kernels gives

$$ \pi(p\mid y)\ \propto\ p^4(1-p)^6p(1-p)^2 =p^5(1-p)^8. $$

The normalizing integral is the beta integral \(B(6,9)\):

$$ \int_0^1 p^5(1-p)^8\,dp =B(6,9) =\frac{\Gamma(6)\Gamma(9)}{\Gamma(15)} =\frac{1}{18018}. $$

Thus the posterior density is \(18018p^5(1-p)^8\), or \(p\mid y\sim\operatorname{Beta}(6,9)\). It is proper, has support within the valid probability range, and its posterior mean is \(6/(6+9)=0.4000\). This mean is the posterior expected event probability under the stated model and prior; it is not a statement that the event probability is known to equal 0.4000.

Support Must Match the Parameter Definition

Before selecting a prior family, identify the parameter's mathematically valid range. Some common clinical-trial parameters have different supports even when they describe related effects. An event probability belongs to \([0,1]\); an event rate belongs to \((0,\infty)\); a risk difference \(p_T-p_C\) belongs to \([-1,1]\); and a hazard ratio belongs to \((0,\infty)\). The log hazard ratio, \(\theta=\log(\text{hazard ratio})\), belongs to the real line.

A prior that violates the parameter's support is not merely surprising; it defines a model in which impossible parameter values can occur. One way to avoid that problem is to place a prior directly on the constrained parameter using a distribution supported on its valid range. Another is to transform the parameter to an unconstrained scale and specify a prior there. The transformation must be stated clearly, and the induced distribution on the original scale must respect its constraints.

Worked Example: A Prior on the Log Hazard Ratio

Suppose a trial models the treatment-to-control hazard ratio \(H\), which must be positive. Define \(\theta=\log H\) and assign the prior \(\theta\sim N(0,0.4^2)\). This normal prior is proper on the real line, and the transformation \(H=\exp(\theta)\) guarantees \(H>0\).

For instance, the prior probability that the hazard ratio is below one is

$$ P(H<1)=P(\exp(\theta)<1) =P(\theta<0)=0.5000, $$

because the normal distribution is symmetric about zero. Its central 95% prior interval for \(\theta\) is approximately \(0\pm1.96(0.4)=[-0.784,0.784]\). Transforming both endpoints gives a central 95% prior interval for \(H\) of approximately \([\exp(-0.784),\exp(0.784)]=[0.4566,2.190]\). Both limits are positive, as a hazard ratio must be.

By contrast, assigning a normal prior directly to \(H\) would generally assign some probability to negative hazard ratios, which are invalid. The log-scale construction avoids that support error. It does not, by itself, establish that the prior is clinically appropriate; that requires considering whether the implied range of hazard ratios is reasonable for the trial question.

Improper Priors and Event-Rate Data

Improper priors are sometimes used for mathematical convenience, but their posterior propriety depends on the observed data and likelihood. Consider an exponential event-time model with rate \(\lambda>0\). For independent event and right-censoring times under the usual noninformative-censoring likelihood, let \(d\) be the number of observed events and \(T\) the total observed time at risk. The likelihood kernel for \(\lambda\) is \(\lambda^d\exp(-\lambda T)\). Use of that likelihood assumes the exponential model and that the observed event and censoring information has been summarized correctly in \(d\) and \(T\).

With an improper flat prior on \(\lambda>0\), the posterior normalizing integral is

$$ \int_0^\infty \lambda^d e^{-\lambda T}\,d\lambda =\frac{\Gamma(d+1)}{T^{d+1}}, \qquad T>0,\ d\geq 0. $$

The equality follows by substituting \(u=T\lambda\), so \(d\lambda=du/T\) and \(\lambda^d=u^d/T^d\). The integral becomes \(T^{-(d+1)}\int_0^\infty u^d e^{-u}\,du=\Gamma(d+1)/T^{d+1}\), which is finite and positive for \(T>0\) and nonnegative integer \(d\). The normalized posterior is then \(\operatorname{Gamma}(d+1,\text{rate }T)\). This calculation justifies posterior propriety for positive total exposure; it does not make the prior itself proper.

Worked Example: Checking a Flat Prior for an Event Rate

Consider hypothetical exponential-model data with \(d=3\) observed events over \(T=12\) person-years of follow-up. Assume the event-time model and censoring-likelihood conditions just stated, and use the improper prior \(\pi(\lambda)\propto1\) for \(\lambda>0\). The posterior kernel is \(\lambda^3e^{-12\lambda}\), and its integral is

$$ \int_0^\infty \lambda^3e^{-12\lambda}\,d\lambda =\frac{\Gamma(4)}{12^4} =\frac{6}{20736} =\frac{1}{3456}. $$

This is finite and positive, so normalization gives \(\lambda\mid y\sim\operatorname{Gamma}(4,\text{rate }12)\). The posterior mean rate is \(4/12=0.3333\) events per person-year. The calculation supports a proper posterior for these data, while the prior remains improper.

The zero-exposure boundary case requires care. In a Poisson count model with exposure \(E\), the exact likelihood is \(P(Y=y\mid\lambda)=e^{-\lambda E}(\lambda E)^y/y!\). If \(E=0\) and \(y=3\), this likelihood is zero for every \(\lambda\): the data have zero likelihood, the normalizing integral is zero, and no posterior can be formed. If \(E=0\) and \(y=0\), the likelihood is instead one for every \(\lambda\); under the flat prior its integral over \(0<\lambda<\infty\) is infinite, so again there is no proper posterior. The positive-exposure gamma-integral argument applies only when \(E>0\) (or, in the survival formulation, \(T>0\)).

Diagnostics, Alternatives, and Limitations

For any proposed prior, first write the valid parameter space \(\Theta\), then check both the prior's support and its total mass. For any posterior calculation, inspect the tail behavior of \(L(\theta;y)\pi(\theta)\) and check that its integral is strictly between zero and infinity. In numerical work, a sampler that fails to explore tails or appears highly sensitive to arbitrary bounds can be a warning sign, but successful computation is not a proof of propriety. Analytical tail checks, where available, are important.

Several failure modes are especially useful to recognize:

  • Invalid support: a direct prior on a positive rate or ratio assigns mass to negative values.
  • Unnormalizable prior called “uninformative”: a constant density over an unbounded range has infinite total mass, not a uniform probability distribution.
  • Posterior assumed proper automatically: an improper prior can yield an infinite normalizing integral or, if the observed data have zero likelihood throughout its support, a zero one.
  • Boundary confusion: a continuous prior on an interval generally assigns zero probability to any single point, including an endpoint. If a point value is scientifically important, a continuous density alone does not assign it positive prior probability.
  • Support mistaken for plausibility: excluding impossible values is necessary but does not establish that the prior mass over possible values is sensible for the clinical context.

A proper prior is a complete probability model and can support prior predictive calculations. An improper prior can sometimes give a mathematically proper posterior, as the event-rate example shows, but it has no normalized prior probabilities and cannot be used as a prior probability distribution for those calculations. A constrained prior specified directly on the valid range makes support explicit. A transformed-scale prior can also enforce constraints, provided the transformation and resulting scale are reported. These are alternatives with different modeling implications, not interchangeable labels for the same prior.

ChoiceWhat must be checkedPractical implication
Proper prior on the parameter's valid rangeIts density or masses sum or integrate to oneDefines prior probabilities and supports prior predictive analysis
Improper prior on an unbounded rangeThe posterior normalizing integral is finite and positiveMay yield a valid posterior, but is not itself a probability distribution
Prior on a transformed parameterThe transformation maps to valid original-scale valuesCan enforce constraints, but interpretation is scale-dependent

A further limitation is that propriety is a mathematical condition, not a measure of scientific quality. A proper prior can be badly calibrated or place substantial mass on implausible values. Conversely, an improper prior that yields a proper posterior does not automatically make the analysis robust. Prior choice should therefore be documented in terms of the parameter, its valid range, the prior distribution, and the reason that distribution is reasonable for the trial.

Key takeaway: A usable posterior requires a positive, finite normalizing integral, and a coherent model requires prior support compatible with the parameter's definition. Check both conditions explicitly; neither one implies the other.

Check Your Understanding

Answer each question, then compare your reasoning with the solutions below.

  1. What two conditions must the posterior normalizing integral satisfy?
  2. A constant prior kernel is used for a rate \(\lambda>0\). Is this a proper prior? What additional check is needed before using the posterior?
  3. In the event-rate Poisson model, what happens with \(E=0,y=2\), and what happens with \(E=0,y=0\) under a flat prior on \(\lambda>0\)?
  4. Why can a normal prior on a log hazard ratio be valid when a normal prior directly on the hazard ratio may not be?

Solutions. (1) The integral must be strictly positive and finite: \(0<Z(y)<\infty\). (2) It is improper because its integral over the positive half-line is infinite; check whether the likelihood times this prior kernel has a finite, positive integral for the observed data. (3) For \(E=0,y=2\), the exact likelihood is zero for every \(\lambda\), so the normalizing integral is zero and no posterior exists. For \(E=0,y=0\), the likelihood is constant, so its integral against the flat prior is infinite and the posterior cannot be normalized. (4) The log hazard ratio ranges over the real line, so a normal prior on it maps through exponentiation to strictly positive hazard ratios; a normal prior directly on the ratio can assign probability to negative, invalid values.

Clinical Biostats