Using Stata v9 to model complex non-linear relationships with restricted cubic splines
Restricted cubic splines (RCSs) are used with generalized linear models and other regression methods to model complex non-linear relationships. A RCS with k knots is linear before the first and after the last knot, is a cubic polynomial between adjacent knots, and is continuous and smooth. A RCS model with k knots can be fitted with only k-1 covariates. rc_spline calculates these covariates from an independent covariate and the knot values. Default numbers of knots and/or knot values suggested by Harrell (2001) may be used. We can then use the full power of Stata v9 to build models, construct graphs, and perform residual analyses using these covariates. RCSs are illustrated by modeling length of stay (LOS) and discharge mortality as a function of admission blood pressure (BP) from the SUPPORT study. LOS and log-odds of death are highly non-linear functions of BP. Multiple linear and logistic regression with RCSs are used to model these data. Plots of expected outcome with 95% confidence bands are easily overlaid on scatterplots using standard Stata graphics. These regression curves are little affected by the knot placements. This robust methodology is easily taught to non-statisticians and greatly expands the modeling capacity of standard regression methods.
Year of publication: |
2005-07-12
|
---|---|
Authors: | Dupont, William D. ; Plummer, Dale |
Institutions: | Stata User Group |
Saved in:
Saved in favorites
Similar items by person
-
Exact confidence intervals for odds ratios from case-control studies
Dupont, William D., (2000)
-
Density Distribution Sunflower Plots in Stata Version 8
Dupont, William D., (2004)
-
Using density-distribution sunflower plots to explore bivariate relationships in dense data
Dupont, William D., (2005)
- More ...