Why Bounds Matter
Some outcomes have scientifically meaningful limits. A percentage cannot be below 0% or above 100%; a concentration known to be nonnegative cannot be negative; and a score defined on a fixed scale cannot exceed its maximum. A fitted regression curve that crosses such a limit may give impossible predictions, even if it tracks the observed data reasonably well.
The issue is not simply whether each observed outcome falls within its limits. A fitted relationship gives a predicted outcome at each predictor value, including values between those recorded in the data. To evaluate a candidate form, check its predictions throughout the observed predictor range, locate any violations, and decide whether the form should be changed or constrained.
A bound on the outcome does not, by itself, specify the shape of the relationship. Many curves can stay within the same limits while differing in curvature and fit to the data. Conversely, a good-looking fit at the observed data points may still be implausible between them. Bounds are one criterion for assessing a candidate form, not a substitute for examining data support and residual patterns.
What Exactly Must Stay Within Bounds?
This tutorial focuses on the fitted relationship: the predicted outcome at each predictor value. If every possible outcome is known to lie between \(L\) and \(U\), its conditional mean must also lie between those bounds. For a regression model, the fitted value is used to estimate that mean. An unconstrained model can nevertheless produce fitted values outside the limits, because its mathematical form is not automatically restricted to the scientifically possible range.
This is different from checking whether every observation lies within the bounds, which is usually guaranteed by how the outcome is defined. It is also different from checking whether an uncertainty interval crosses a bound. A fitted value can be valid while an interval around it extends outside the limits; that raises a question about uncertainty, not whether the point fit itself violates the bounds.
First identify the predictor range supported by the data, say \(a \leq x \leq b\), and the justified outcome limits. Then inspect the fitted curve throughout that interval. Do not assume that a curve is valid just because its predictions at the observed predictor values are valid: a curved fit may leave the permitted range between observations.
Checking a Candidate Curve
For a simple polynomial, the range over an interval can often be checked by evaluating the fitted values at the endpoints and at any interior turning points. For a more complicated fitted curve, examine its behavior over a dense grid across the observed predictor range. A grid is a practical way to locate suspicious regions, but it is not always a mathematical guarantee: a narrow violation can fall between grid points. When the curve’s form allows it, use its extrema or other analytical checks to confirm the result.
For example, if an interior point \(x^\ast\) is a local maximum or minimum of a differentiable curve, the derivative there must be zero. This follows from the fact that a differentiable curve at an interior extremum has no nonzero instantaneous slope: a positive or negative slope would allow a nearby value to be higher or lower. Thus, for a quadratic, checking its endpoints and its vertex is enough to find its range on a finite interval. For a spline or other flexible form, check the pieces and locations where the curve can attain an extremum, or use numerical evaluation followed by a suitable verification.
Worked Example: Locating a Negative Prediction
Suppose a candidate quadratic predicts an outcome \(Y\) in units where negative values are impossible. The observed predictor range is \(0 \leq x \leq 10\), and the plausible outcome bounds are 0 and 40. The candidate fitted curve is \(\hat{Y}=18+8x-1.2x^2\). Does it respect the bounds across this range?
The derivative is \(8-2.4x\), so the only interior turning point is \(x=8/2.4=3.333\). Its fitted value is
The endpoint values are \(\hat{Y}(0)=18\) and \(\hat{Y}(10)=18+80-120=-22\). Since the quadratic opens downward, its vertex is the maximum. The endpoint and vertex checks therefore show that the maximum on the interval is about 31.33, within the upper bound, but the minimum is \(-22\), below the lower bound.
To find where the fitted value crosses the lower bound, solve \(18+8x-1.2x^2=0\). Rearranging and applying the quadratic formula gives
The roots are approximately \(-1.777\) and \(8.443\). Only the second lies in the observed range. The fitted values are negative for \(8.443 < x \leq 10\), so this candidate violates the lower bound over that part of the range. This identifies where the problem occurs; it does not, by itself, establish that a different curve would fit the observations better.
Ways to Respect a Bound
When a bound is essential, the most direct solution is to choose or fit a form whose predictions are restricted to the plausible range. One option for two finite bounds is to model a transformed mean and map it back to the outcome scale. For example, define
where \(\eta(x)\) is an unrestricted fitted expression. For any finite real value of \(\eta(x)\), the fraction \(1/(1+\exp\{-\eta(x)\})\) lies strictly between 0 and 1. Therefore, the fitted value lies strictly between \(L\) and \(U\). This is a way to build the bounds into the form itself rather than discover impossible predictions after fitting.
The particular form still needs to be appropriate for the relationship and data. A bounded form may have different curvature from an unconstrained polynomial, and the bounds alone do not guarantee that its fitted values follow the observed pattern well. Compare candidate forms using the data and the intended prediction task as well as the scientific limits.
Worked Example: A Form Bounded Between 0 and 100
Suppose a hypothetical outcome is a percentage, so its fitted value must be between 0 and 100. Over the observed predictor range \(0 \leq x \leq 10\), consider the bounded form
At \(x=0\), the inner expression is \(-2\), so
At \(x=10\), the inner expression is 3, giving
These endpoint predictions are within the limits, and the form stays within them at every predictor value, not just at the endpoints: its denominator is greater than 1 for any finite inner expression, so its predicted percentage is strictly between 0 and 100. This guarantees plausible range, but it does not establish that the curve fits any particular data set well.
Another approach is constrained fitting, where the fitting procedure is restricted so predictions satisfy specified bounds over the relevant range. The constraints must apply wherever the curve is required to be plausible, not only at a few selected data points. Whether such a procedure is available and how it is implemented depends on the model and software being used.
Simply clipping an unconstrained prediction to the nearest bound is different. Clipping changes the predictions after the curve has been fitted; it does not make the fitted relationship itself respect the bounds. It can create flat sections at the limits and can disguise how far, or where, the original curve was implausible. If clipping is used for a practical prediction rule, explain that choice and evaluate the resulting predictions as a separate rule.
Worked Example: Valid Endpoints, Invalid Interior
A hypothetical outcome is a proportion, so its bounds are 0 and 1. The predictor ranges from 0 to 1, and a candidate fitted curve is \(\hat{Y}(x)=0.2+4x(1-x)\). At both endpoints, \(\hat{Y}(0)=\hat{Y}(1)=0.2\), which might make an endpoint-only check seem reassuring. But the derivative is \(4-8x\), so the interior maximum occurs at \(x=0.5\):
The fitted value exceeds the upper bound. To locate the violation, solve \(0.2+4x(1-x)>1\). Rearranging gives \(4x^2-4x+0.8<0\); the corresponding roots are
Because the quadratic opens upward after rearrangement, the inequality holds between its roots. Thus the original fitted curve exceeds 1 for approximately \(0.2764 < x < 0.7236\), despite meeting the bounds at both endpoints. The check must cover the interior of the predictor range.
Common Mistakes and Practical Reporting
- Checking only the observed pairs. A fitted curve is defined between observed predictor values too. Check the whole observed range, not just the locations of recorded observations.
- Treating a high or low prediction as merely unlikely. If a scientific bound is genuinely hard, a prediction outside it is impossible, not simply surprising. First confirm the units, coding, and stated limits; then assess the candidate form.
- Assuming a bounded form must be a good fit. Staying within limits is necessary when the limits are hard, but it does not show that the curve captures the data pattern or predicts accurately.
- Clipping and calling the original fit bounded. Clipping alters predictions after fitting. Report it as a separate adjustment, or use a form or fitting procedure that incorporates the limits.
- Extending the conclusion beyond the checked range. A curve that respects bounds over the observed predictor range may behave differently outside it. A range check within the data does not establish plausibility for extrapolated predictions.
A concise report should name the outcome limits and the predictor interval checked, describe how the curve was checked, and state any violating range. If a bounded form was used, explain that it enforces the limits and assess its fit separately. Bounds are scientifically useful precisely because they reveal when mathematical convenience has led a candidate curve to make an impossible claim.
Check Your Understanding
Answer each question using the distinction between a curve’s shape and its plausible outcome range.
- A fitted curve remains within the outcome limits at every observed predictor value. What additional check is needed before concluding it respects the bounds over the observed predictor range?
- For a differentiable quadratic on a closed interval, which locations are sufficient to check when finding its minimum and maximum?
- A proportion model predicts 1.08 at some predictor value. If the proportion’s valid range is 0 to 1, what does this say about the candidate fitted relationship?
- Why does clipping predictions to a limit not make the original fitted curve a bounded form?
- A model’s point predictions stay within the outcome bounds, but an uncertainty interval extends above the upper bound. Is that a violation by the point fit, the uncertainty interval, or both? Explain.