Description Usage Arguments Value Note Author(s) See Also Examples
Simulates data for two cancers, A and B.
1 2 | simSeerSet(N=2e9,yearEnd=2016,ka=1e-5,kb=0.04,Ab=1e-5,
tauA=10,tauB=1,delay=1,period=4)
|
N |
Number of person years to simulate. Default is roughly that of SEER. |
yearEnd |
Most recent SEER year to simulate. |
ka |
Rate at which cancer A incidence increases linearly with age. |
kb |
Exponential aging rate constant for cancer B incidence. |
Ab |
Exponential amplitude for cancer B incidence. |
tauA |
Survival mean in years for cancer A. |
tauB |
Survival mean in years for cancer B. |
delay |
Years until the beginning of the excess risk of B. |
period |
Duration in Years of the excess risk of B. |
A simulated seerSet object with popsa filled using US 2000 Std population proportions and canc with
cancers A and B
where the incidence of A increases linearly with age and B increase exponentially in age.
Survival times are assumed to be exponentially distributed with means of tauA years for A and tauB years for B.
Radiation therapy of A is assumed to increase RR of B to 5 uniformly for period
years after delay
years.
Supported by the Cleveland Clinic Foundation.
Tom Radivoyevitch (radivot@ccf.org)
SEERaBomb-package, seerSet,mk2D, plot2D
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | ## Not run:
library(SEERaBomb)
n=simSeerSet()
n=mk2D(n,secondS="B")
mybrks=c(0,0.75,0.9,1.1,1.25,2,2.5,3,3.5,4,4.75,4.9,5.1,5.25,6)
n=tsd(n,brks=mybrks,trts=c("rad","noRad"))
D=mkDF(n)%>%filter(cancer1=="A")%>%select(t,RR,L=rrL,U=rrU,trt)
head(D,2)
library(ggplot2)
theme_update(legend.position = c(.8, .815),
axis.text=element_text(size=rel(1.2)),
axis.title=element_text(size=rel(1.3)),
legend.title=element_text(size=rel(1.2)),
legend.text=element_text(size=rel(1.2)))
g=qplot(x=t,y=RR,col=trt,data=D,geom=c("line","point"),
xlab="Years Since First Cancer Diagnosis",ylab="Relative Risk")
g+geom_abline(intercept=1, slope=0)+geom_errorbar(aes(ymin=L,ymax=U,width=.05))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.