Description Usage Arguments Examples

The printout provides numbered labels for the terminal nodes, a description of the split at each node, the number of observations found at each node, and the predicted spline coefficients for each node. This code is primarily taken from rpart base code for print.rpart. It has been modified to ensure that the full vector of coefficients is printed for each node.

1 |

`t` |
A model returned by splineTree() |

`cp` |
Optional- if provided, a pruned version of the tree will be printed. The tree will be pruned using the provided cp as the complexity parameter. |

`digits` |
Specifies how many digits of each coefficient should be printed |

1 2 3 4 5 6 | ```
split_formula <- ~HISP + WHITE + BLACK + SEX + Num_sibs + HGC_FATHER + HGC_MOTHER
tree <- splineTree(split_formula, BMI~AGE, idvar = "ID",
data = nlsySample, degree = 1, df = 3,
intercept = TRUE, cp = 0.005)
stPrint(tree)
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.