Objective: Ordinary least squares (OLS) regression, commonly called linear regression, is often used to assess, or adjust for, the relationship between a continuous independent variable and the mean of a continuous dependent variable, implicitly assuming a linear relationship between them. Linearity may not hold, however, and analyzing the mean of the dependent variable may not capture the full nature of such relationships. Our goal is to demonstrate how combined use of quantile regression and restricted cubic splines (RCS) can reveal the true nature and complexity of relationships between continuous variables.
Study design and setting: We provide a review of methodologic concepts, followed by two examples using real data sets. In the first example, we analyzed the relationship between cognition and disease duration in multiple sclerosis. In the second example, we analyzed the relationship between length of stay (LOS) and severity of illness in the intensive care unit (ICU).
Results: In both examples, quantile regression showed that the relationship between the variables of interest was heterogeneous. In the second example, RCS uncovered nonlinearity of the relationship between severity of illness and length of stay.
Conclusion: Together, quantile regression and RCS are a powerful combination for exploring relationships between continuous variables.