next up previous
Next: 6. Up: 5. Previous: 5.2

5.3 Broken stick regression

Useful for systems that may suffer a "shock".

Another application of categorical variables.

../Images/bstick.gif

Model:


\begin{displaymath}Av(Y\vert x,z) = \beta_0 + \beta_1 x + \beta_2\times z\times (x - T),\end{displaymath}

where z = 0 if x < T and z = 1 if $x \ge T$, and T is the "breakpoint".

Case 1, x < T, plug in to get

\begin{displaymath}Av(Y\vert x,z) = \beta_0 + \beta_1 x + \beta_2\times 0\times (x - T),\end{displaymath}


\begin{displaymath}Av(Y\vert x,z) = \beta_0 + \beta_1 x,\end{displaymath}

Case 2, $x \ge T$, plug in to get

\begin{displaymath}Av(Y\vert x,z) = \beta_0 + \beta_1 x + \beta_2\times 1\times (x - T),\end{displaymath}


\begin{displaymath}Av(Y\vert x,z) = \beta_0 + \beta_1 x + \beta_2 (x - T),\end{displaymath}


\begin{displaymath}Av(Y\vert x,z) = \beta_0 - \beta_2 T + (\beta_1 + \beta_2) x,\end{displaymath}

Slope before T is $\beta_1$, slope after T is $\beta_1 + \beta_2$.

Therefore $\beta_2$ measures the change in slope after time T.

Implementation in S-Plus.

*
1. Create the indicator variable column z.
*
2. Create a new column by multiplying column z by column x.
*
3. Run the regression with column x and the "product column".

Technical name: Piecewise linear regression.

Issues: searching for the breakpoint.


next up previous
Next: 6. Up: 5. Previous: 5.2
Richard Waterman
1999-09-13