plotsurv {spatsurv} | R Documentation |
plotsurv function
Description
A function to produce a 2-D plot of right censored spatial survival data.
Usage
plotsurv(
spp,
ss,
maxcex = 1,
transform = identity,
background = NULL,
eventpt = 19,
eventcol = "red",
censpt = "+",
censcol = "black",
xlim = NULL,
ylim = NULL,
xlab = NULL,
ylab = NULL,
add = FALSE,
...
)
Arguments
spp |
A spatial points data frame |
ss |
A Surv object (with right-censoring) |
maxcex |
maximum size of dots default is equavalent to setting cex equal to 1 |
transform |
optional transformation to apply to the data, a function, for example 'sqrt' |
background |
a background object to plot default is null, which gives a blamk background note that if non-null, the parameters xlim and ylim will be derived from this object. |
eventpt |
The type of point to illustrate events, default is 19 (see ?pch) |
eventcol |
the colour of events, default is black |
censpt |
The type of point to illustrate events, default is "+" (see ?pch) |
censcol |
the colour of censored observations, default is red |
xlim |
optional x-limits of plot, default is to choose this automatically |
ylim |
optional y-limits of plot, default is to choose this automatically |
xlab |
label for x-axis |
ylab |
label for y-axis |
add |
logical, whether to add the survival plot on top of an existing plot, default is FALSE, which produces a plot in a new device |
... |
other arguments to pass to plot |
Value
Plots the survival data non-censored observations appear as dots and censored observations as crosses. The size of the dot is proportional to the observed time.