Description Usage Arguments Value Examples
This function adds a text label to the plot, which is preceded by a small identifier, similar to the function nrAtRisk.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 | 
| text | String, content of the label. | 
| x | A numeric value for the position at the x-axis. | 
| y | A numeric value for the position at the y-axis. | 
| font | Font of the label. | 
| cex | Font size of the label | 
| col.text | Color of the label. | 
| len.flag | Length of the flag. | 
| lty.flag | Line-typ of the flag. Value is 1 if not spezified. | 
| lwd.flag | Line-wide of the flag. Value is 1 if not spezified. | 
| bgcol.flag | Background-color of the flag (corresponding to the color of the confidence interval in the plot). No color if not value is specified. | 
| lncol.flag | Color of the line of the flag. Default is "black". | 
Draws the number at risk to an existing plot.
| 1 2 3 4 5 6 7 8 9 10 |   require(survival)
  aml_model <- with(aml, survfit(Surv(time, status)~x))
  col1 <- adjustcolor("red",0.2); col2 <- adjustcolor("blue",0.2)
  survPlot(xmax=50)
  confIntArea(aml_model, col=col1, group=1)
  confIntArea(aml_model, col=col2, group=2)
  survCurve(aml_model, group=1)
  survCurve(aml_model, group=2, lty=2)
  survLable("maintain", 1, 0.2, bgcol.flag=col1)
  survLable("non-maint.", 1, 0.1, bgcol.flag=col2, lty.flag=2)
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.