View source: R/BackSelection.R

BackSelection | R Documentation |

Build the model through backward selection

```
BackSelection(data, Type, variables, continuous, TD, NL, m = 1, p = 2,
alpha_back = 0.05, knots = -999)
```

`data` |
A data frame in the long (interval) format with one line per unit of time. |

`Type` |
A vector consisting the name of variables representing the start and stop of each time interval and event indicator. e.g. c("start","stop","event"). |

`variables` |
A vector consisting the name of varialbes that will be adjusted in the model. |

`continuous` |
A vector of binary indicators representing whether the corresponding variables are continuous variables (1=Yes, 0=NO) |

`TD` |
A vector representing whether to force the corresponding variable having a time-dependent
effect. Only takes three values: |

`NL` |
A vector representing whether to force the corresponding variable having a non-linear
effect. Only takes three values: |

`m` |
The number of interior knots used in the regression B-spline, default value is 1 |

`p` |
The degree of the regression B-spline, default value is 2 |

`alpha_back` |
significane level used in the backward elemination process |

`knots` |
Default value is -999 |

Note that the TD and NL arguments have different meanings than that in the `CoxFlex`

and `tvcFlex`

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.