Author-reviewedEvidence: highv1.0.0

Flexible Parametric Model

A flexible parametric model is a fully specified regression model that represents a transformed survival function with smooth functions of time, commonly restricted cubic splines, so complex hazards and time-varying effects can be estimated and extrapolated.

Last reviewed byDr Darrin Baines

Concept Architecture

Flexible Parametric Model

This page explains the Royston–Parmar formulation most often meant in survival analysis, how its scale and spline structure work, how predictions enter health-economic models, and why long-term extrapolation still requires clinical and external validation.

Why flexible parametric survival models are used

Standard parametric survival distributions impose a small set of hazard shapes, while the Cox model leaves the baseline hazard unspecified. Flexible parametric survival models occupy a useful middle ground: they estimate a smooth parametric baseline that can follow complex observed patterns while retaining direct prediction beyond observed event times.

This combination is valuable when analysts need smooth estimates of survival, hazards, restricted mean survival, or time-varying treatment effects. It is especially relevant to health technology assessment, where trial follow-up is often shorter than the economic model's time horizon.

Survival, hazard, and cumulative hazard

The survival function gives the probability of remaining event-free beyond time tt, and the hazard describes the instantaneous event rate among those still at risk. The cumulative hazard connects these quantities and provides a convenient modelling scale.

S(t)=Pr⁡(T>t),H(t)=∫0th(u) du,S(t)=exp⁡{−H(t)}.S(t)=\Pr(T>t), \qquad H(t)=\int_0^t h(u)\,du, \qquad S(t)=\exp\{-H(t)\}.

Once a model supplies a valid cumulative hazard, survival follows directly from this relationship. The instantaneous hazard can be obtained by differentiating the cumulative hazard with respect to time, provided the fitted function remains mathematically valid over the prediction range.

The Royston–Parmar model

The common proportional-hazards version models the log cumulative hazard as a smooth function of log time plus covariate effects. Restricted cubic splines provide the flexibility while remaining linear beyond the boundary knots on the chosen transformed scale.

log⁡H(t∣x)=s ⁣(log⁡t;γ,κ)+xTβ,\log H(t\mid\mathbf x) =s\!\left(\log t;\boldsymbol\gamma,\boldsymbol\kappa\right) +\mathbf x^{\mathsf T}\boldsymbol\beta,

where s(⋅)s(\cdot) is a restricted cubic spline, γ\boldsymbol\gamma contains spline coefficients, κ\boldsymbol\kappa contains knot locations, and β\boldsymbol\beta contains covariate coefficients. With no time interactions, exponentiating a coefficient gives a constant hazard ratio under the proportional-hazards formulation.

What restricted cubic splines contribute

A cubic spline joins polynomial pieces at selected knot locations while imposing continuity and smoothness at each join. The restriction to linear behaviour beyond the boundary knots stabilises the tails relative to an unrestricted cubic polynomial, but it does not guarantee clinically plausible long-term extrapolation.

Spline complexity is commonly controlled through degrees of freedom or the number and placement of internal knots. Too little flexibility can miss turning points or non-monotonic hazards, whereas too much flexibility can follow random variation, create unstable tail behaviour, or produce imprecise predictions.

Modelling choicePractical effect
Fewer spline degrees of freedomProduces a smoother baseline but may underfit genuine hazard changes
More spline degrees of freedomCaptures more local shape but can overfit sparse event data
Interior knot placementDetermines where the fitted function can change curvature most readily
Boundary knot placementInfluences the region in which the spline becomes linear on its modelled scale
Time transformationCommonly uses log⁡t\log t to distribute flexibility across early and later follow-up

Choosing the modelled scale

Flexible parametric models can apply a link function to survival and model the transformed quantity with a spline. The link determines the interpretation of covariate effects and the class of assumptions made when effects are time-constant.

ScaleExample formulationTime-constant effect implies
Log cumulative hazardlog⁡H(t∣x)=η(t,x)\log H(t\mid\mathbf x)=\eta(t,\mathbf x)Proportional hazards
Log cumulative oddslog⁡{[1−S(t∣x)]/S(t∣x)}=η(t,x)\log\{[1-S(t\mid\mathbf x)]/S(t\mid\mathbf x)\}=\eta(t,\mathbf x)Proportional odds
Probit survivalΦ−1{1−S(t∣x)}=η(t,x)\Phi^{-1}\{1-S(t\mid\mathbf x)\}=\eta(t,\mathbf x)Proportional probit-scale effects

The best scale is not determined by fit statistics alone. Analysts should examine whether its effect interpretation, fitted hazards, residual behaviour, observed-data fit, and extrapolated shape are suitable for the clinical process and decision problem.

Allowing treatment effects to change over time

Proportional hazards may be implausible when treatment effects emerge slowly, wane, or change after treatment stops. A flexible parametric model can represent a time-varying coefficient by interacting the treatment or covariate with a spline function of time.

log⁡H(t∣x)=s0(log⁡t)+xTβ+z s1(log⁡t),\log H(t\mid\mathbf x) =s_0(\log t)+\mathbf x^{\mathsf T}\boldsymbol\beta +z\,s_1(\log t),

where zz identifies the covariate with a time-varying effect and s1(log⁡t)s_1(\log t) describes how its effect changes. The resulting hazard ratio is a function of time, so reporting one constant hazard ratio would discard the feature the model was introduced to capture.

From the linear predictor to survival

For a model fitted on the log cumulative-hazard scale, predictions can be recovered through simple transformations. The transformation converts the unrestricted linear-predictor scale into valid cumulative-hazard and survival scales. If η(t,x)\eta(t,\mathbf x) is the fitted linear predictor, then

H(t∣x)=exp⁡{η(t,x)},S(t∣x)=exp⁡[−exp⁡{η(t,x)}].H(t\mid\mathbf x)=\exp\{\eta(t,\mathbf x)\}, \qquad S(t\mid\mathbf x)=\exp[-\exp\{\eta(t,\mathbf x)\}].

The hazard requires the derivative of the smooth time function and should normally be obtained from validated software. Survival probabilities must remain between zero and one and non-increasing, while cumulative hazards must be non-negative and non-decreasing.

Worked prediction example

Consider an illustrative log cumulative-hazard model whose fitted linear predictor at time tt is η(t)=−3+1.2log⁡(t)−0.4z\eta(t)=-3+1.2\log(t)-0.4z, where z=1z=1 denotes treatment and z=0z=0 denotes comparator. This simple segment behaves like a low-complexity member of the broader flexible-parametric family and demonstrates how the fitted scale becomes a survival probability.

At t=2t=2 years for treatment,

η(2)=−3+1.2log⁡(2)−0.4=−2.5682,\eta(2)=-3+1.2\log(2)-0.4=-2.5682, H(2)=exp⁡(−2.5682)=0.0767,S(2)=exp⁡(−0.0767)=0.9262.H(2)=\exp(-2.5682)=0.0767, \qquad S(2)=\exp(-0.0767)=0.9262.

For the comparator, η(2)=−2.1682\eta(2)=-2.1682, so H(2)=0.1145H(2)=0.1145 and S(2)=0.8918S(2)=0.8918. These are conditional model predictions from invented coefficients, not clinical estimates, and their plausibility would still need to be assessed against observed and external evidence.

Predictions available from the model

The smooth fully parametric representation supports a wider range of predictions than a baseline-free Cox model without additional estimation steps. Predictions can be made for specified covariate patterns and then standardised over a target population when marginal results are required.

  • A flexible parametric model can predict survival and failure probabilities at clinically meaningful times.
  • A flexible parametric model can predict hazards, cumulative hazards, hazard ratios, and hazard differences over time.
  • A flexible parametric model can estimate survival differences and ratios without assuming that these contrasts remain constant.
  • A flexible parametric model can estimate restricted mean survival time by integrating the survival curve over a defined horizon.
  • A flexible parametric model can support standardised or marginal predictions by averaging individual predictions over a target covariate distribution.

Conditional and marginal effects answer different questions and need not coincide in nonlinear survival models. The estimand, covariate distribution, prediction horizon, and treatment-switching assumptions should therefore accompany every reported prediction.

Integrating survival for economic evaluation

Expected time alive over a horizon τ\tau equals the area under the survival curve up to that horizon. This makes survival extrapolation directly consequential for life-years, quality-adjusted life-years, and costs.

RMST⁡(τ)=∫0τS(t) dt.\operatorname{RMST}(\tau)=\int_0^{\tau}S(t)\,dt.

If utility varies by health state or time, the survival function enters a weighted integral rather than automatically equalling quality-adjusted survival. Numerical integration should use sufficiently small intervals or an accurate quadrature method, and the result should be checked against software-generated restricted mean survival where available.

Extrapolation beyond observed follow-up

Flexible fit within the observed data does not ensure reliable behaviour after follow-up ends. Beyond the last informative events, predictions are driven increasingly by spline tail restrictions, model scale, knot choices, covariate assumptions, and any imposed treatment-effect structure.

Analysts should compare extrapolated hazards and survival with clinical expectations, longer-term studies, registries, general-population mortality, biological constraints, and alternative plausible models. Model averaging or scenario analysis may be more honest than selecting one curve when several extrapolations fit observed data similarly but imply materially different long-term outcomes.

Treatment-effect extrapolation

A treatment effect estimated during a trial may not persist unchanged over a lifetime. Flexible time-varying effects can describe observed non-proportionality, but the spline should not be allowed to invent an unsupported long-term benefit or harm after information becomes sparse.

Economic evaluations should test explicit scenarios such as full persistence, gradual waning, convergence to no effect, or a clinically justified stopping rule. Each scenario should identify the time at which extrapolation begins, its functional form, and the evidence or judgement supporting it.

Selecting knots and degrees of freedom

Candidate models commonly vary the baseline degrees of freedom, time-varying-effect degrees of freedom, scale, and covariate specification. Information criteria can help compare fitted likelihood and complexity, but small numerical differences do not establish better clinical extrapolation.

Plots of fitted survival and hazards, residual diagnostics, parameter uncertainty, and sensitivity to knot placement are essential. Knot selection should be prespecified where possible, and alternative reasonable specifications should be retained when they materially change decision-relevant predictions.

Diagnostics within observed data

Model checking should compare predictions with non-parametric summaries over the period in which data are informative. Kaplan–Meier curves help assess survival fit, while smoothed hazards, cumulative hazards, residuals, and time-dependent effect plots can reveal discrepancies hidden by survival curves alone.

Agreement should be checked overall and across treatment or prognostic groups that matter to the decision. Sparse tails should not receive the same visual or inferential weight as periods with many people at risk and many observed events.

Background mortality and relative survival

For long horizons, all-cause mortality predictions should remain compatible with population mortality appropriate to age, sex, calendar period, and other relevant characteristics. Relative-survival models can separate expected population mortality from excess mortality associated with the condition.

Adding background mortality mechanically to an incompatible fitted all-cause model can double-count risk. The analyst should state whether the model targets all-cause, cause-specific, or excess mortality and ensure that mortality components combine coherently.

Cure and competing-risk structures

A flexible parametric baseline does not by itself establish that a cured fraction exists or solve a competing-risks problem. Cure models require a substantively justified long-term structure, while competing-risk predictions require cause-specific or subdistribution modelling that respects the dependence of cumulative incidence on all event causes.

Cause-specific flexible parametric models can be combined to estimate cumulative incidence, but summing independently predicted cause-specific probabilities is generally invalid. The implementation should verify that predicted state occupancy and cumulative incidence remain coherent across all causes and times.

Comparison with adjacent survival models

Flexible parametric models share features with several familiar survival approaches but differ in what is specified and what can be predicted directly. Understanding these distinctions helps analysts choose a model because it suits the estimand rather than because one method appears universally more advanced.

ModelBaseline time patternMain strengthMain caution
Cox proportional-hazards modelLeft unspecifiedRobust estimation of a proportional relative effectAbsolute extrapolation requires additional baseline modelling
Standard parametric modelFixed distributional familyParsimony and transparent tail behaviourLimited hazard shapes may underfit complex data
Flexible parametric modelSmooth parametric function, often spline-basedRich absolute and time-varying predictionsTail behaviour can be sensitive to specification
Piecewise exponential modelConstant hazard within intervalsTransparent interval-specific hazardsResults depend on interval placement and may be non-smooth
Cure modelMixture or non-mixture long-term structureRepresents a clinically justified cured fractionCure assumptions may dominate immature-data extrapolation

Software implementation

Flexible parametric survival models should be fitted in software that correctly constructs spline bases, censoring likelihoods, derivatives, predictions, and uncertainty intervals. Established implementations include stpm2 in Stata and rstpm2 in R, while other survival packages provide related spline-based parametric models with different parameterisations.

Analysts should record the software, package and version, time origin, time units, censoring and truncation rules, model scale, spline degrees of freedom, knot locations, covariates, interactions, and prediction commands. Coefficients from different parameterisations should not be assumed interchangeable merely because both models are described as flexible parametric.

Common errors and safeguards

Flexible parametric models can produce smooth and convincing curves even when the underlying specification is weak. The following safeguards focus attention on the assumptions that most affect interpretation and economic results.

  • Analysts should not select a model solely because it has the lowest Akaike or Bayesian information criterion within observed follow-up.
  • Analysts should inspect hazards as well as survival because materially different hazard shapes can yield similar short-term survival curves.
  • Analysts should model non-proportional effects explicitly when a constant-effect assumption is not defensible.
  • Analysts should avoid adding spline complexity that is unsupported by the number and timing of events.
  • Analysts should validate extrapolated mortality against external evidence and plausible population constraints.
  • Analysts should distinguish conditional predictions from marginal or standardised treatment effects.
  • Analysts should propagate parameter uncertainty through survival, cost, and quality-adjusted life-year calculations.
  • Analysts should test knot, scale, treatment-waning, and extrapolation choices in scenario and sensitivity analyses.

A defensible modelling workflow

A strong flexible-parametric analysis connects the clinical event process, observed data, mathematical specification, and decision horizon. The workflow below makes each modelling choice visible and testable.

  1. Define the event, time origin, censoring, truncation, estimand, target population, and prediction horizon.
  2. Inspect Kaplan–Meier estimates, numbers at risk, event timing, and plausible hazard patterns.
  3. Specify candidate model scales, baseline spline complexities, covariates, and time-varying effects.
  4. Fit candidate models using validated survival-analysis software and reproducible settings.
  5. Check convergence, parameter estimates, predicted probability constraints, and numerical stability.
  6. Compare observed-data fit using survival, hazard, residual, and subgroup diagnostics rather than one statistic alone.
  7. Validate extrapolated survival and hazards against clinical knowledge, external data, and population mortality.
  8. Calculate decision-relevant predictions, including survival contrasts and integrated life-years, with uncertainty.
  9. Test alternative knots, scales, treatment-effect waning, background mortality, and structurally different models.
  10. Report the complete specification, diagnostics, external validation, extrapolation assumptions, and decision impact.

Interpretation and limitations

The word flexible describes the range of shapes the model can represent, not freedom from assumptions. Results remain conditional on the chosen link scale, spline basis, knot placement, proportionality structure, covariates, censoring assumptions, extrapolation rule, and available event information.

Smooth curves may conceal wide uncertainty or implausible tail behaviour, particularly when follow-up is immature. Decision makers should see both central predictions and credible alternative extrapolations so that model flexibility improves understanding rather than creating false confidence.

Library

Publications

1
  • Guidance

    NICE DSU Technical Support Document 14: Survival analysis for economic evaluations alongside clinical trials – extrapolation with patient-level data — Nicholas R. Latimer, TSD 14 ed., 2013 (NICE Decision Support Unit (University of Sheffield))

    The reference guidance on survival analysis for economic evaluation: fitting standard parametric models (exponential, Weibull, Gompertz, log-logistic, log-normal) to censored trial data and extrapolating to estimate lifetime survival benefit, with a process guide for model selection and justification.

Frequently Asked Questions (6)

  • What is a flexible parametric model?

    A class of survival models using flexible functions, such as restricted cubic splines, to represent the hazard or survival function beyond standard distributions.

    Source: Royston & Parmar 2002

  • Why can standard distributions be too rigid for some survival data?

    A standard survival distribution imposes one fixed shape on the hazard over time, such as always rising or always falling, which may not match data whose risk changes direction or has more than one turning point. Flexible parametric models relax this by using adjustable functions, typically splines, that can bend to follow complex hazard patterns while remaining fully parametric and so usable for extrapolation. They occupy a middle ground between rigid standard forms and the non-parametric Kaplan-Meier estimate. Royston and Parmar (2002) developed this approach.

    Source: Royston & Parmar 2002

  • How do flexible parametric models work?

    Flexible parametric models work by modelling a transformation of the survival function, commonly the log cumulative hazard, as a flexible function of log time using restricted cubic splines, with knots placed along the time scale. The splines allow the hazard to take complex shapes, while the parametric form gives a smooth, fully specified model that can be extrapolated. Covariates can be included, and the number and placement of knots control the flexibility, so the model adapts to the data's hazard pattern.

    Source: Royston & Parmar 2002

  • What are the advantages of flexible parametric models?

    Flexible parametric models can represent complex hazard shapes, such as those that rise then fall, that standard distributions cannot, giving better fit where the hazard is not simple. Being fully parametric, they provide smooth survival and hazard functions and can be extrapolated, unlike non-parametric methods. They accommodate covariates and time-varying effects. This combination of flexibility and parametric structure makes them useful in survival analysis and extrapolation where simple distributions fit poorly but a smooth, extendable model is wanted.

    Source: Latimer 2013

  • What is the role of splines in flexible parametric models?

    Splines, typically restricted cubic splines, are the means by which flexible parametric models achieve their flexibility: they represent the log cumulative hazard as a smooth, piecewise function of log time, able to bend at specified knots to follow complex hazard shapes. The knots determine where the function can change, and their number controls the flexibility, more knots allowing more complex shapes but risking overfitting. Splines thus let the model depart from the fixed forms of standard distributions while remaining smooth and parametric.

    Source: Royston & Parmar 2002

  • What are the limitations of flexible parametric models?

    Flexible parametric models require choices about the number and placement of knots, which affect the fit and the extrapolation, and too many knots risk overfitting the observed data and producing implausible projections beyond it. Their flexibility within the data does not guarantee sensible extrapolation, since the fitted shape may not hold in the tail. They are also more complex than simple distributions. These limitations mean knot choices are made carefully and the extrapolated behaviour scrutinised for plausibility, as with other survival models.

    Source: Latimer 2013

Trust Record

Verified by Dr Darrin Baines

British health economist

Professional identity: darrinbaines.org

Verification date: 23 Sep 2026

Content version: 1.0.0

Canonical Identity

Term code
HE-EM-SM-023

Stable URI · Machine-readable · Resolvable · CC BY 4.0