spBayesSurv: Fitting Bayesian Spatial Survival Models Using R - arXiv

6 downloads 106868 Views 1MB Size Report
May 10, 2017 - Journal of Statistical Software. MMMMMM .... code below is run in R version 3.3.3 under the platform x86 64-apple-darwin13.4.0 (64-bit). 2.
Journal of Statistical Software

JSS

arXiv:1705.04584v1 [stat.CO] 10 May 2017

MMMMMM YYYY, Volume VV, Issue II.

doi: 10.18637/jss.v000.i00

spBayesSurv: Fitting Bayesian Spatial Survival Models Using R Haiming Zhou Northern Illinois University

Timothy Hanson

Jiajia Zhang

University of South Carolina University of South Carolina

Abstract Spatial survival analysis has received a great deal of attention over the last 20 years due to the important role that geographical information can play in predicting survival. This paper provides an introduction to a set of programs for implementing some Bayesian spatial survival models in R using the package spBayesSurv, version 1.1.1. The function survregbayes includes three most commonly-used semiparametric models: proportional hazards, proportional odds, and accelerated failure time. All manner of censored survival times are simultaneously accommodated including uncensored, interval censored, current-status, left and right censored, and mixtures of these. Left-truncated data are also accommodated leading to models for time-dependent covariates. Both georeferenced and areally observed spatial locations are handled via frailties. Model fit is assessed with conditional Cox-Snell residual plots, and model choice is carried out via LPML and DIC. The accelerated failure time frailty model with a covariate-dependent baseline is included in the function frailtyGAFT. In addition, the package also provides two marginal survival models: proportional hazards and linear dependent Dirichlet process mixture, where the spatial dependence is modeled via spatial copulas. Note that the package can also handle non-spatial data using non-spatial versions of aforementioned models.

Keywords: Bayesian nonparametric, survival analysis, spatial dependence, semiparametric models, parametric models.

1. Introduction Spatial location plays a key role in survival prediction, serving as a proxy for unmeasured regional characteristics such as socioeconomic status, access to health care, pollution, etc. Literature on the spatial analysis of survival data has flourished over the last decade, including the study of leukemia survival (Henderson, Shimakura, and Gorst 2002), childhood mortality (Kneib 2006), asthma (Li and Lin 2006), breast cancer (Banerjee and Dey 2005; Zhou,

2

spBayesSurv, version 1.1.1

Hanson, Jara, and Zhang 2015a), political event processes (Darmofal 2009), prostate cancer (Wang, Zhang, and Lawson 2012; Zhou, Hanson, and Zhang 2017), pine trees (Li, Hong, Thapa, and Burkhart 2015a), threatened frogs (Zhou, Hanson, and Knapp 2015b), health and pharmaceutical firms (Arbia, Espa, Giuliani, and Micciolo 2016), emergency service response times (Taylor 2017), and many others. Here we introduce the spBayesSurv package for fitting various survival models to spatiallyreferenced survival data. Note that all models included in this package can also be fit without spatial information, including nonparametric models as well as semiparametric proportional hazards (PH), proportional odds (PO), and accelerated failure time (AFT) models. The model parameters and statistical inference are carried out via self-tuning adaptive Markov chain Monte Carlo (MCMC) methods; no manual tuning is needed. The R syntax is essentially the same as for existing R survival functions. Sensible, well-tested default priors are used throughout, however, the user can easily implement informative priors if such information is available. The primary goal of this paper is to introduce spBayesSurv and provide extensive examples of its use. Comparisons to other models and R packages can be found in Zhou et al. (2015b), Zhou et al. (2017), and Zhou and Hanson (2017). Section 2 discusses spBayesSurv’s implementation of PH, PO, and AFT frailty models for georeferenced (e.g. latitude and longitude are recorded) and areally-referenced (e.g. county of residence recorded) spatial survival data; the functions also work very well for exchangeable or no frailties. The models are centered at a parametric family through a novel transformed Bernstein polynomial prior and the centering family can be tested versus the Bernstein extension via Bayes factors. All manner of censoring is accommodated as well as left-truncated data; left-truncation also allows for the inclusion of time-dependent covariates. Both the DIC and LPML statistics are available for model selection; spike-and-slab variable selection is also implemented. In Section 3, a generalized AFT model is implemented allowing for continuous stratification. That is, the baseline survival function is itself a function of covariates: baseline survival changes smoothly as a function of continuous predictors; for categorical predictors the usual stratified AFT model is obtained. Note that even for the usual stratified semiparametric AFT model with one discrete predictor (e.g. clinic) it is extremely difficult to obtain inference using frequentist approaches; see Chiou, Kang, and Yan (2015) for a recent development. The model fit in spBayesSurv actually extends discrete stratification to continuous covariates, allowing for very general models to be fit. The generalized AFT model includes the easy computation of Bayes factors for determining which covariates affect baseline survival and whether a parametric baseline is adequate. Finally, Section 4 offers a spatial implementation of the completely nonparametric linear dependent Dirichlet process mixture (LDDPM) model of De Iorio, Johnson, M¨ uller, and Rosner (2009) for georeferenced data. The LDDPM does not have one simple “linear predictor” as do the models in Sections 2 and 3, and therefore a marginal copula approach was taken to incorporate spatial dependence. A piecewise-constant baseline hazard PH model is also implemented via spatial copula for comparison purposes, i.e. a Bayesian version of the model presented in Li and Lin (2006). Section 5 concludes the paper with a discussion. Although there are many R packages for implementing survival models, there are only a handful of that allow the inclusion of spatial information and these focus almost exclusively on variants of the PH model. BayesX (Belitz, Brezger, Klein, Kneib, Lang, and Umlauf

Journal of Statistical Software

3

2015) is an immensely powerful standalone program for fitting various generalized additive mixed models, including both georeferenced and areally-referenced frailties in the PH model. The package R2BayesX (Umlauf, Adler, Kneib, Lang, and Zeileis 2015) interfaces BayesX with R, but does not appear to include the full functionality of BayesX, e.g. a Bayesian approach for interval-censored data is not included. For georeferenced frailties BayesX uses what have been termed “Matern splines,” first introduced in an applied context by Kammann and Wand (2003). Several authors have used this approach including Kneib (2006), Hennerfeind, Brezger, and Fahrmeir (2006), and Kneib and Fahrmeir (2007). This approximation was termed a “predictive process” and given a more formal treatment by Banerjee, Gelfand, Finley, and Sang (2008) and Finley, Sang, Banerjee, and Gelfand (2009). In our experience, the predictive process tends to give biased regression effects and prediction when the rank (i.e. the number of knots) was chosen too low; the problem worsened with no replication and/or when spatial correlation was high. In spBayesSurv the full-scale approximation (FSA) of Sang and Huang (2012) is used to fix the predictive process via tapering; see Section 2.1.4. The package spatsurv (Taylor and Rowlingson 2017) includes an implementation of PH allowing for georeferenced Gaussian process frailties. The frailty process is approximated on a fine grid and the covariance matrix inverted via the discrete Fourier transform on block circulent matrices; see Taylor (2015) for details. Taylor’s approach vastly improves computation time over a fully-specified Gaussian process. Both R2BayesX and spatsurv focus on the PH model with right-censored data. The spBayesSurv includes several other spatial frailty models for general interval-censored and/or left-truncated data, and two marginal copula models for right-censored data, which have been shown to provide dramatically improved fit over frailty models (Zhou et al. 2015b; Li, Hanson, and Zhang 2015b). To set notation, suppose subjects are observed at m distinct spatial locations s1 , . . . , sm . Let tij be a random event time associated with the jth subject in si and P xij be a related pdimensional vector of covariates, i = 1, . . . , m, j = 1, . . . , ni . Then n = m i=1 ni is the total number of subjects under consideration. Assume the survival time tij lies in the interval (aij , bij ), 0 ≤ aij ≤ bij ≤ ∞. Here left censored data are of the form (0, bij ), right censored (aij , ∞), interval censored (aij , bij ) and uncensored values simply have aij = bij , i.e., we define (x, x) = {x}. Therefore, the observed data will be D = {(aij , bij , xij , si ); i = 1, . . . , m, j = 1, . . . , ni }. For areally-observed outcomes, e.g. county-level, there is typically replication (i.e. ni > 1); for georeferenced data, there may or may not be replication. Note although the models are discussed for spatial survival data, non-spatial data are also accommodated. All code below is run in R version 3.3.3 under the platform x86 64-apple-darwin13.4.0 (64-bit).

2. Semiparametric Frailty Models 2.1. Models The function survregbayes supports three commonly-used semiparametric frailty models: AFT, PH, and PO. The AFT model has survival and density functions 0

0

0

Sxij (t) = S0 (exij β+vi t), fxij (t) = exij β+vi f0 (exij β+vi t),

(1)

while the PH model has survival and density x0ij β+vi

Sxij (t) = S0 (t)e

0

x0ij β+vi

, fxij (t) = exij β+vi S0 (t)e

−1

f0 (t),

(2)

4

spBayesSurv, version 1.1.1

and the PO model has survival and density 0

0

Sxij (t) =

e−xij β−vi S0 (t) 0

1 + (e−xij β−vi − 1)S0 (t)

, fxij (t) =

e−xij β−vi f0 (t) 0

[1 + (e−xij β−vi − 1)S0 (t)]2

,

(3)

where β = (β1 , . . . , βp )0 is a vector of regression coefficients, vi is an unobserved frailty associated with si , and S0 (t) is the baseline survival with density f0 (t) corresponding to xij = 0 and vi = 0. Let Γ(a, b) denote a gamma distribution with mean a/b. The survregbayes function implements the following prior distributions: β ∼ Np (β 0 , S0 ), S0 (·)|α, θ ∼ TBPL (α, Sθ (·)), α ∼ Γ(a0 , b0 ), θ ∼ N2 (θ 0 , V0 ), (v1 , . . . , vm )0 |τ ∼ ICAR(τ 2 ), τ −2 ∼ Γ(aτ , bτ ), or

(4)

(v1 , . . . , vm )0 |τ, φ ∼ GRF(τ 2 , φ), τ −2 ∼ Γ(aτ , bτ ), φ ∼ Γ(aφ , bφ ), or (v1 , . . . , vm )0 |τ ∼ IID(τ 2 ), τ −2 ∼ Γ(aτ , bτ ) where TBPL , ICAR, GRF and IID refer to the transformed Bernstein polynomial (TBP) (Chen, Hanson, and Zhang 2014; Zhou and Hanson 2017) prior, intrinsic conditionally autoregressive (ICAR) (Besag 1974) prior, Gaussian random field (GRF) prior, and independent Gaussian (IID) prior distributions, respectively. We briefly introduce these priors but leave details to Zhou and Hanson (2017).

TBP prior In semiparametric survival analysis, a wide variety of Bayesian nonparametric priors can be used to model S0 (·); see M¨ uller, Quintana, Jara, and Hanson (2015) and Zhou and Hanson (2015) for reviews. The TBP prior is attractive in that it is centered at a given parametric family and it selects only smooth densities. For a fixed positive integer L, the prior TBPL (α, Sθ (·)) is defined as S0 (t) =

L X

wj I(Sθ (t)|j, L − j + 1), wL ∼ Dirichlet(α, . . . , α),

(5)

j=1

where wL = (w1 , . . . , wL )0 is a vector of positive weights, I(·|a, b) denotes a beta cumulative distribution function (cdf) with parameters (a, b), and {Sθ (·) : θ ∈ Θ} is a parametric family of survival functions with support on positive reals R+ . The log-logistic Sθ (t) = exp(θ2 ) }−1 , the log-normal S (t) = 1−Φ{(log t+θ ) exp(θ )}, and the Weibull S (t) = {1+(eθ1 t) 1 2 θ θ  1 − exp −(eθ1 t)exp(θ2 ) families are implemented in survregbayes, where θ = (θ1 , θ2 )0 . In our experience, the three centering distributions yield almost identical posterior inferences but in small samples one might be preferred. The random distribution S0 (·) is centered at Sθ (·), i.e. E[S0 (t)|α, θ] = Sθ (t). The parameter α controls how close the weights wj are to 1/L, i.e. how close the shape of the baseline survival S0 (·) is relative to the prior guess Sθ (·). Large values of α indicate a strong belief that S0 (·) is close to Sθ (·); as α → ∞, S0 (·) → Sθ (·) with probability 1. Smaller values of α allow more pronounced deviations of S0 (·) from Sθ (·). This adaptability makes the TBP prior attractive in its flexibility, but also anchors the random S0 (·) firmly about Sθ (·): wj = 1/L for j = 1, . . . , L implies S0 (t) = Sθ (t) for t ≥ 0. Moreover, unlike the mixture of Polya trees (Lavine 1992) or mixture of Dirichlet process (Antoniak 1974) priors, the TBP prior selects smooth densities, leading to efficient posterior sampling.

Journal of Statistical Software

5

ICAR and IID priors For areal data, the ICAR prior smooths neighboring geographic-unit frailties v = (v1 , . . . , vm )0 . Let eij be 1 if regions i and j share a common boundary and 0 otherwise; set eii = 0. Then the m × m matrix E = [eij ] is called the adjacency matrix for the m regions. The prior ICAR(τ 2 ) on v is defined through the set of the conditional distributions   m X vi |{vj }j6=i ∼ N  eij vj /ei+ , τ 2 /ei+  , i = 1, . . . , m, (6) j=1

Pm

where ei+ = j=1 eij is the number of neighbors of area si . The induced prior on v under Pm ICAR is improper; the constraint j=1 vj = 0 is used for identifiability (Banerjee, Carlin, and Gelfand 2014). For non-spatial data, we consider the independent Gaussian prior IID(τ 2 ), defined as iid

v1 , v2 , . . . , vm ∼ N (0, τ 2 ).

(7)

GRF priors For georeferenced data, it is commonly assumed that vi = v(si ) arises from a Gaussian random field (GRF) {v(s), s ∈ S} such that v = (v1 , . . . , vm ) follows a multivariate Gaussian distribution as v ∼ Nm (0, τ 2 R), where τ 2 measures the amount of spatial variation across locations and the (i, j) element of R is modeled as R[i, j] = ρ(si , sj ). Here ρ(·, ·) is a correlation function controlling the spatial dependence of v(s). In survregbayes the powered exponential correlation function ρ(s, s0 ) = ρ(s, s0 ; φ) = exp{−(φks − s0 k)ν } is used, where φ > 0 is a range parameter controlling the spatial decay over distance, ν ∈ (0, 2] is a pre-specified shape parameter, and ks − s0 k refers to the distance (e.g., Euclidean, great-circle) between s and s0 . Therefore, the prior GRF(τ 2 , φ) is defined as   X vi |{vj }j6=i ∼ N − pij vj /pii , τ 2 /pii  , i = 1, . . . , m, (8) {j:j6=i}

where pij is the (i, j) element of R−1 .

Full-scale approximation As m increases evaluating R−1 from R becomes computationally impractical. To overcome this computational issue, we consider the FSA (Sang and Huang 2012) due to its capability of capturing both large- and small-scale spatial dependence. Consider a fixed set of “knots” S ∗ = {s∗1 , . . . , s∗K } chosen from the study region. These knots are chosen using the function cover.design within the R package fields, which computes space-filling coverage designs using the swapping algorithm (Johnson, Moore, and Ylvisaker 1990). Let ρ(s, s0 ) be the correlation between locations s and s0 . The FSA approach approximates the correlation function ρ(s, s0 ) with ρ† (s, s0 ) = ρl (s, s0 ) + ρs (s, s0 ). (9) The ρl (s, s0 ) in (9) is the reduced-rank part capturing the long-scale spatial dependence, ∗ ∗ 0 ∗ ∗ ∗ K defined as ρl (s, s0 ) = ρ0 (s, S ∗ )ρ−1 KK (S , S )ρ(s , S ), where ρ(s, S ) = [ρ(s, si )]i=1 is a K × 1

6

spBayesSurv, version 1.1.1

∗ vector, and ρKK (S ∗ , S ∗ ) = [ρ(s∗i , s∗j )]K i,j=1 is a K ×K correlation matrix at knots S . However, ρl (s, s0 ) cannot well capture the short-scale dependence due to the fact that it discards entirely the residual part ρ(s, s0 ) − ρl (s, s0 ). The idea of FSA is to add a small-scale part ρs (s, s0 ) as a sparse approximate of the residual part, defined by ρs (s, s0 ) = {ρ(s, s0 ) − ρl (s, s0 )} ∆(s, s0 ), where ∆(s, s0 ) is a modulating function, which is specified so that ρs (s, s0 ) can well capture the local residual spatial dependence while still permitting efficient computation. Motivated by Konomi, Sang, and Mallick (2014), we first partition the total input space into B disjoint blocks, and then specify ∆(s, s0 ) in a way such that the residuals are independent across input blocks, but the original residual dependence structure within each block is retained. Specifically, the function ∆(s, s0 ) is taken to be 1 if s and s0 belong to the same block and 0 otherwise. The approximated correlation function ρ† (s, s0 ) in (9) provides an exact recovery of the true correlation within each block, and the approximation errors are ρ(s, s0 ) − ρl (s, s0 ) for locations s and s0 in different blocks. Those errors are expected to be small for most entries because most of these location pairs are farther apart. To determine the blocks, we first use the R function cover.design to choose B ≤ m locations among the m locations forming B blocks, then assign each si to the block that is closest to si . Here B does not need to be equal to K. When B = 1, no approximation is applied to the correlation ρ. When B = m, it reduces to the approach of Finley et al. (2009), so the local residual spatial dependence may not be well captured.

Applying the above FSA approach to approximate the correlation function ρ(s, s0 ), we can approximate the correlation matrix R with  −1 0 0 ρ†mm = ρl + ρs = ρmK ρ−1 KK ρmK + ρmm − ρmK ρKK ρmK ◦ ∆,

(10)

m where ρmK = [ρ(si , s∗j )]i=1:m,j=1:K , ρKK = [ρ(s∗i , s∗j )]K i,j=1 , and ∆ = [∆(si , sj )]i,j=1 . Here, the notation “◦” represents the element-wise matrix multiplication. To avoid numerical instability, we add a small nugget effect  = 10−10 when defining R, that is, R = (1 − )ρmm + Im . It follows from equation (10) that R can be approximated by 0 R† = (1 − )ρ†mm + Im = (1 − )ρmK ρ−1 KK ρmK + Rs ,

 0 where Rs = (1 − ) ρmm − ρmK ρ−1 KK ρmK ◦ ∆ + Im . Applying the Sherman-WoodburyMorrison formula for inverse matrices, we can approximate R−1 by 

R†

−1

 −1 0 −1 0 −1 = R−1 ρmK R−1 s − (1 − )Rs ρmK ρKK + (1 − )ρmK Rs ρmK s .

In addition, the determinant of R can be approximated by    −1 det R† = det ρKK + (1 − )ρ0mK R−1 det(Rs ). s ρmK det(ρKK )

(11)

(12)

Since the m × m matrix Rs is a block matrix, the right-hand sides of equations (11) and (12) involve only inverses and determinants of K × K low-rank matrices and m × m block diagonal matrices. Thus the computational complexity can be greatly reduced relative to the expensive computational cost of using original correlation function for large value of m.

2.2. MCMC

Journal of Statistical Software

7

The likelihood function for (wL , θ, β, v) is given by L(wL , θ, β, v) =

ni m Y Y 

I{aij > > > > > > > > >

library(coda) library(survival) library(spBayesSurv) library(fields) library(BayesX) library(R2BayesX) data(LeukSurv); attach(LeukSurv); d = LeukSurv[order(district),]; n = nrow(d); detach(LeukSurv); head(d); time cens xcoord ycoord age sex wbc tpi district 24 1 1 0.4123484 0.4233738 44 1 281.0 4.87 1 62 3 1 0.3925028 0.4531422 72 1 0.0 7.10 1 68 4 1 0.4167585 0.4520397 68 0 0.0 5.12 1 128 9 1 0.4244763 0.4123484 61 1 0.0 2.90 1 129 9 1 0.4145535 0.4520397 26 1 0.0 6.72 1 163 15 1 0.4013230 0.4785006 67 1 27.9 1.50 1 > nwengland=read.bnd(system.file("otherdata/nwengland.bnd", + package="spBayesSurv")); > adj.mat=bnd2gra(nwengland) > E = diag(diag(adj.mat)) - as.matrix(adj.mat); The following code is used to fit the PO model with ICAR frailties using the TBP prior with L = 15 and default settings for other priors. A burn-in period of 5,000 iterates was considered and the Markov chain was subsampled every 5 iterates to get a final chain size of 2,000. The argument ndisplay=1000 will display the number of saved scans after every 1,000 saved iterates. If the argument InitParamMCMC=TRUE (not used here as it is the default setting), then an initial chain with nburn=5000, nsave=5000, nkip=0 and ndisplay=1000 will be run; otherwise, the initial values are obtained from fitting parametric non-frailty models via survreg. The total running time is 166 seconds. > set.seed(1) > mcmc=list(nburn=5000, nsave=2000, nskip=4, ndisplay=1000); > prior=list(maxL=15); > ptm res1 = survregbayes(formula=Surv(time,cens)~age+sex+wbc+tpi + +frailtyprior("car",district),data=d,survmodel="PO", + dist="loglogistic",mcmc=mcmc,prior=prior,Proximity=E); Starting initial MCMC based on parametric model: scan = 1000

Journal of Statistical Software

9

scan = 2000 scan = 3000 scan = 4000 scan = 5000 Starting the MCMC for the semiparametric model: scan = 1000 scan = 2000 > systime1=proc.time()-ptm; systime1; user system elapsed 165.919 0.296 166.354 The term frailtyprior("car",district) indicates that the ICAR prior in (6) is used. One can also incorporate the IID prior in (7) via frailtyprior("iid",district). The non-frailty model can be fit by removing the frailtyprior term. The argument survmodel is used to indicate which model will be fit; choices include "PH", "PO", and "AFT". The argument dist is used to specify the distribution family of Sθ (·) defined in Section 2.1, and the choices include "loglogistic", "lognormal", and "weibull". The argument prior is used to specify user-defined hyperparameters, e.g., for p = 3, L = 15, β 0 = 0, S0 = 10Ip , θ 0 = 0, V0 = 10I2 , a0 = b0 = 1, and aτ = bτ = 1, the prior can be specified as below. > prior=list(maxL=15,beta0=rep(0,3),S0=diag(10,3),theta0=rep(0,2), + V0=diag(10,2),a0=1,b0=1,taua0=1,taub0=1) If prior=NULL, then the default hyperparameters given in Section 2.2 would be used. Note by default survregbayes standardizes each covariate by subtracting the sample mean and dividing the sample standard deviation. Therefore, the user-specified hyperparameters should be based on the model with scaled covariates unless the argument scale.designX=FALSE is added. The output from applying the summary function to the returned object res1 is given below. > sfit1=summary(res1); sfit1 Proportional Odds model: Call: survregbayes(formula = Surv(time, cens) ~ age + sex + wbc + tpi + frailtyprior("car", district), data = d, survmodel = "PO", dist = "loglogistic", mcmc = mcmc, prior = prior, Proximity = E) Posterior inference of regression coefficients (Adaptive M-H acceptance rate: 0.2731): Mean Median Std. Dev. 95%CI-Low age 0.0519835 0.0518955 0.0034329 0.0455544 sex 0.1238558 0.1241657 0.1061961 -0.0854203 wbc 0.0059439 0.0059223 0.0008163 0.0043996 tpi 0.0598826 0.0597254 0.0159244 0.0286519 Posterior inference of precision parameter (Adaptive M-H acceptance rate: 0.2723):

95%CI-Upp 0.0589767 0.3274537 0.0074789 0.0904957

10

spBayesSurv, version 1.1.1 sex

wbc

0

500

1000 1500 2000

0.004

0.045

−0.2 0.0

0.006

0.2

0.055

0.4

0.008

age

0

500

1000 1500 2000

500

500

1000 1500 2000

1000 1500 2000

alpha

1

2

3

4

5

0.0 0.2 0.4 0.6 0.8

0.06 0.02 0

0

tau^2

0.10

tpi

0

500

1000 1500 2000

0

500

1000 1500 2000

Figure 1: Leukemia survival data. Trace plots for β, τ 2 and α under the PO model with ICAR frailties.

alpha

Mean 1.2910

Median 1.1227

Std. Dev. 0.7158

95%CI-Low 0.4364

95%CI-Upp 3.1922

Posterior inference of conditional CAR frailty variance Mean Median Std. Dev. 95%CI-Low 95%CI-Upp variance 0.080346 0.056350 0.082950 0.001709 0.299395 Log pseudo marginal likelihood: LPML=-5925.194 Deviance Information Criterion: DIC=11849.82 Number of subjects: n=1043 We can see that age, wbc and tpi are significant risk factors for leukemia survival. For example, lower age decreases the odds of a patient dying by any time; holding other predictors constant, a 10-year decrease in age cuts the odds of dying by exp(−10 × 0.05) ≈ 60%. The posterior mean for τ 2 is 0.08, and is 1.29 for precision parameter α. The LPML and DIC are -5925 and 11850, respectively. The following code is used to produce trace plots (Figure 1) for β, τ 2 and α. Note that the mixing for τ 2 is not very satisfactory. This is not surprising, since we are using very vague gamma prior Γ(0.001, 0.001) and the total number of districts is only 24. > > > > > > > >

par(mfrow=c(3,2)); par(cex=1,mar=c(2.5,4.1,1,1)) traceplot(mcmc(res1$beta[1,]), xlab="", main="age") traceplot(mcmc(res1$beta[2,]), xlab="", main="sex") traceplot(mcmc(res1$beta[3,]), xlab="", main="wbc") traceplot(mcmc(res1$beta[4,]), xlab="", main="tpi") traceplot(mcmc(res1$tau2), xlab="", main="tau^2") traceplot(mcmc(res1$alpha), xlab="", main="alpha")

The code below is used to generate the Cox-Snell plots with 10 posterior residuals (Figure 2, panel a).

11

age=49 age=65 age=74

0.6 0.4

0

0.0

1

0.2

2

3

Survival Probability

4

0.8

5

1.0

Journal of Statistical Software

0

0

1

2

(a)

3

4

5

1000

2000

3000

4000

5000

−0.23

0

0.23

Time (days)

(b)

(c)

Figure 2: Leukemia survival data. PO model with ICAR frailties. (a) Cox-Snell plot. (b) Survival curves with 95% credible interval bands for female patients with wbc=38.59 and tpi=0.3398 at different ages. (c) Map for the posterior mean frailties; larger frailties mean higher mortality rate overall. > > > > > > > > > + > > + + + +

set.seed(1) nrand = 10; Resid = cox.snell.survregbayes(res1, ncurves=nrand); r.max = ceiling(quantile(res1$Surv.cox.snell[,1], .99))+1 xlim=c(0, r.max); ylim=c(0, r.max); width=8; height=8; xx = seq(0, r.max, 0.01); fit = survfit(Resid$resid1~1); par(cex=1.5,mar=c(2.1,2.1,1,1),cex.lab=1.4,cex.axis=1.1) plot(fit, fun="cumhaz", conf.int=F, mark.time=FALSE, xlim=xlim, ylim=ylim, lwd=2, lty=2) lines(xx, xx, lty=1, lwd=3, col="darkgrey") for(i in 2:nrand){ fit = survfit(Resid[[i+1]]~1); lines(fit, fun="cumhaz", conf.int=F, mark.time=FALSE, xlim=xlim, ylim=ylim, lwd=2, lty=2) }

The code below is used to generate survival curves for female patients with wbc=38.59 and tpi=0.3398 at different ages (Figure 2, panel b). > > + + > > > > + >

tgrid = seq(0.1,5000,length.out=300); xpred = rbind(c(49, 0, 38.59, 0.3398), c(65, 0, 38.59, 0.3398), c(74, 0, 38.59, 0.3398)); estimates=plot(res1, xpred=xpred, tgrid=tgrid); par(mfrow=c(1,1)); par(cex=1.2,mar=c(4.1,4.1,1,1),cex.lab=1.3,cex.axis=1.1) plot(estimates$tgrid, estimates$Shat[,1], "l", lwd=3, ylim = c(0, 1), xlab = "Time (days)", ylab="Survival Probability") polygon(x=c(rev(tgrid),tgrid),

12

spBayesSurv, version 1.1.1

+ + > > + + > > + + > > +

y=c(rev(estimates$Shatlow[,1]),estimates$Shatup[,1]), border=c("black"),col="lightgray"); lines(estimates$tgrid, estimates$Shat[,1], lty=1, lwd=3) polygon(x=c(rev(tgrid),tgrid), y=c(rev(estimates$Shatlow[,2]),estimates$Shatup[,2]), border=c("red"),lty=2, col="lightgray"); lines(estimates$tgrid, estimates$Shat[,2], lty=2, lwd=3, col="red") polygon(x=c(rev(tgrid),tgrid), y=c(rev(estimates$Shatlow[,3]),estimates$Shatup[,3]), border=c("green"),lty=2, col="lightgray"); lines(estimates$tgrid, estimates$Shat[,3], lty=3, lwd=3, col="green") legend(2600,0.95, legend=c("age=49","age=65","age=74"), lty=c(1,2,3),lwd=c(3,3,3),col=c("black","red","green"),bty="n",cex=2)

The code below is used to generate the map of posterior means of frailties for each district (Figure 2, panel c). > > > > > > +

frail0=(rowMeans(res1$v)); #$ frail = frail0[as.integer(names(nwengland))]; values = cbind(as.integer(names(nwengland)), frail) op > > > > > > + + + >

set.seed(1) mcmc=list(nburn=5000, nsave=2000, nskip=4, ndisplay=1000); prior=list(maxL=15, nu=1, nknots=100, nblock=1043); d$ID=1:nrow(d); #$ locations=cbind(d$xcoord,d$ycoord); ptm systime2=proc.time()-ptm; systime2; user system elapsed 10079.006 97.039 10176.650 The trace plots for β, τ 2 and φ (Figure 3), Cox-Snell residuals and survival curves (Figure 4) can be obtained using the same code used for the PO model with ICAR frailties. The code below is used to generate the map of posterior means of frailties for each location (Figure 4). > > > > > > > > > +

frail= round((rowMeans(res2$v)),3); nclust=5; #$ frail.cluster = cut(frail, breaks = nclust); frail.names = names(table(frail.cluster)) rbPal set.seed(1) > res3 = survregbayes(formula=Surv(time,cens)~age+sex+wbc+tpi + +frailtyprior("car",district),data=d,survmodel="PO", + dist="loglogistic",mcmc=mcmc,prior=prior,Proximity=E, + selection=TRUE); > systime3=proc.time()-ptm; systime3; user system elapsed 308.490 0.585 309.524 > sfit3=summary(res3); sfit3 Variable selection: age,wbc,tpi age,sex,wbc,tpi age,wbc prop. 0.8975 0.1010 0.0015 Log pseudo marginal likelihood: LPML=-5924.529 Deviance Information Criterion: DIC=11847.91 Number of subjects: n=1043

2.6. Parametric vs. Semiparametric Many authors have found parametric models to fit as well or better than competing semiparametric models (Cox and Oakes 1984, p. 123; Nardi and Schemper 2003). The proposed semiparametric models have their baseline survival functions centered at a parametric family Sθ (t). Note that zJ−1 = 0 implies S0 (t) = Sθ (t). Therefore, testing H0 : zJ−1 = 0 versus H1 : zJ−1 6= 0 leads to the comparison of the semiparametric model with the underlying parametric model. Let BF10 be the Bayes factor between H1 and H0 . Zhou et al. (2017) proposed to estimate BF10 by a large-sample approximation to the generalized Savage-Dickey density ratio (Verdinelli and Wasserman 1995). Adapting their approach BF10 is estimated d 10 = BF

p(0|ˆ α) ˆ ˆ Σ) NJ−1 (0; m,

,

(15)

where p(0|α) = Γ(αJ)/[J α Γ(α)]J is the prior density of zJ−1 evaluated at zJ−1 = 0, α ˆ is the posterior mean of α, Np (·; m, Σ) denotes a p-variable normal density with mean m and ˆ are posterior mean and covariance of zJ−1 . ˆ and Σ covariance Σ, and m

16

spBayesSurv, version 1.1.1

The Bayes factor BF10 under the semiparametric PO model with ICAR frailties can be obtained using the code below (here the object res1 is obtained in Section 2.4). > BF.survregbayes(res1) [1] 82.12799 The BF10 = 82 > 1 indicates that the semiparametric model outperforms the loglogistic parametric model. The function survregbayes also supports the efficient fitting of parametric frailty models with loglogistic, lognormal or Weibull baseline functions. In parametric models, the prior for θ can be set to be relatively vague. Setting a0 at any negative value will force the α to be fixed at the value specified in the argument state. For example, setting prior=list(a0=-1) and state=list(alpha=1) will fix α = 1 throughout the MCMC; setting prior=list(a0=-1) and state=list(alpha=Inf) will fit a parametric model. The following code fits a parametric loglogistic PO model with ICAR frailties to the leukemia survival data. The LPML is -5950, much worse than the value under the semiparametric PO model. > set.seed(1) > prior=list(maxL=15, a0=-1,thete0=rep(0,2),V0=diag(1e10,2)); > state=list(alpha=Inf); > ptm res11 = survregbayes(formula=Surv(time,cens)~age+sex+wbc+tpi + +frailtyprior("car",district),data=d,survmodel="PO", + dist="loglogistic",mcmc=mcmc,prior=prior,state=state, + Proximity=E,InitParamMCMC=FALSE); scan = 1000 scan = 2000 > sfit11=summary(res11); sfit11 Proportional Odds model: Call: survregbayes(formula = Surv(time, cens) ~ age + sex + wbc + tpi + frailtyprior("car", district), data = d, survmodel = "PO", dist = "loglogistic", mcmc = mcmc, prior = prior, state = state, Proximity = E, InitParamMCMC = FALSE) Posterior inference of regression coefficients (Adaptive M-H acceptance rate: 0.2844): Mean Median Std. Dev. 95%CI-Low age 0.0504253 0.0504362 0.0033318 0.0439945 sex 0.1187297 0.1134544 0.1109109 -0.0912841 wbc 0.0062192 0.0062147 0.0007395 0.0048068 tpi 0.0602207 0.0603376 0.0156038 0.0299010

95%CI-Upp 0.0568477 0.3374972 0.0076600 0.0915584

Posterior inference of baseline parameters Note: the baseline estimates are based on scaled covariates (Adaptive M-H acceptance rate: 0.2723): Mean Median Std. Dev. 95%CI-Low 95%CI-Upp

Journal of Statistical Software theta1 theta2

-5.12778 -0.10741

-5.12791 -0.10619

0.06432 0.02759

-5.25384 -0.16125

17

-5.00723 -0.05445

Posterior inference of conditional CAR frailty variance Mean Median Std. Dev. 95%CI-Low 95%CI-Upp variance 0.078627 0.055078 0.082164 0.002005 0.305202 Log pseudo marginal likelihood: LPML=-5949.919 Deviance Information Criterion: DIC=11899.46 Number of subjects: n=1043 > systime11=proc.time()-ptm; systime11; user system elapsed 25.037 0.115 25.239

2.7. Left-Truncation and Time-Dependent Covariates The survival time tij is left-truncated at uij ≥ 0 if uij is the time when the ijth subject is first observed. Left-truncation often occurs when age is used as the time scale. Given the observed left-truncated data {(uij , aij , bij , xij , si )}, where aij ≥ uij , the likelihood function (13) becomes L(wJ , θ, β, v) =

ni m Y Y  I{aij aij ) = P (tij > aij |tij > tij,oij )

Y

P (tij > tij,k+1 |tij > tij,k )

k=1

=

Sxij,oij (aij )

oij −1

Y Sxij,k (tij,k+1 ) . Sxij,oij (tij,oij ) Sxij,k (tij,k ) k=1

Thus one can replace the observation (uij , aij , bij , xij (t), si ) by a set of new oij observations (tij,1 , tij,2 , ∞, xij,1 , si ), (tij,2 , tij,3 , ∞, xij,2 , si ), . . ., (tij,oij , aij , bij , xij,oij , si ). This way we get a

18

spBayesSurv, version 1.1.1

new left-truncated data set of size L(wJ , θ, β, v) =

ni  h m Y Y

Pm Pni i=1

j=1 oij .

Then the likelihood function becomes

iI{aij > > + + > >

temp systime1=proc.time()-ptm; systime1; user system elapsed 227.626 0.434 228.243 Equivalently, one can also run the following code to obtain the same analysis. The argument truncation_time is used to specify the start time point for each time interval, i.e. tstart. The end time point tstop together with endpt are formulated as interval censored data using type="interval2" of Surv. This format is more general than the former one, as one can easily incorporate interval censored data. > pbc2$tleft=pbc2$tstop; pbc2$tright=pbc2$tstop; > pbc2$tright[which(pbc2$endpt!=2)]=NA; > fit11 = survregbayes(Surv(tleft,tright,type="interval2")~log(bili) + +log(protime), data=pbc2, survmodel="PH", + dist="loglogistic", mcmc=mcmc, + truncation_time=tstart, subject.num=id);

3. GAFT Frailty Models 3.1. The Model The generalized accelerated failure time (GAFT) frailty model (Zhou et al. 2017) generalizes the AFT model (1) to allow the baseline survival function S0 (t) to depend on certain covariates, say a q-dimensional vector zij which is usually a subset of xij . Specifically, the GAFT frailty model is given by   0 Sxij (t) = S0,zij e−xij β−vi t , (16)

20

spBayesSurv, version 1.1.1

or equivalently, ˜ + vi + ij , ˜ 0ij β yij = log(tij ) = x

(17)

˜ = (β0 , β 0 )0 is a vector of corresponding coeffi˜ ij = (1, x0ij )0 includes an intercept, β where x cients, ij is a heteroscedastic error term independent of vi , and P (eβ0 +ij > t|zij ) = S0,zij (t). Note the regression coefficients β here are defined differently with those in model (1). Here we assume ind. ij |Gzij ∼ Gzij , where Gz is a probability measure defined on R for every z ∈ X ; this defines a model for the entire collection of probability measures GX = {Gz : z ∈ X } so that each element is allowed to smoothly change with the covariates z. The frailtyGAFT function considers the following prior distributions: ˜ ∼ Np+1 (m0 , S0 ) β Gz |α, σ 2 ∼ LDTFPL (α, σ 2 ), α ∼ Γ(a0 , b0 ), σ −2 ∼ Γ(aσ , bσ ), (v1 , . . . , vm )0 |τ ∼ ICAR(τ 2 ), τ −2 ∼ Γ(aτ , bτ ), or

(18)

(v1 , . . . , vm )0 |τ, φ ∼ GRF(τ 2 , φ), τ −2 ∼ Γ(aτ , bτ ), φ ∼ Γ(aφ , bφ ), or (v1 , . . . , vm )0 |τ ∼ IID(τ 2 ), τ −2 ∼ Γ(aτ , bτ ) where LDTFPL refers to the linear dependent tailfree process prior (LDTFP) prior as described in (Zhou et al. 2017). The LDTFP prior considered in Zhou et al. (2017) is centered at a normal distribution Φσ with mean 0 and variance σ 2 , that is, E(Gz ) = Φσ for every z ∈ X . Define the function kσ (x) = d2L Φσ (x)e, where dxe is the ceiling function, the smallest integer greater than or equal to x. Further define probability pz (k) for k = 1, . . . , 2L as pz (k) =

L Y

Yl,dk2l−L e (z),

l=1

−1 where Yj+1,2k−1 (z) = 1 + exp{−˜ z0 γ j,k } and Yj+1,2k (z) = 1−Yj+1,2k−1 (z) for j = 0, . . . , L− ˜ = (1, z0 )0 includes an intercept, and γ j,k = (γj,k,0 , . . . , γj,k,q )0 is a 1, k = 1, . . . , 2j , where z vector of coefficients. Note there are 2L − 1 regression coefficient vectors γ = {γ j,k }, e.g. for L = 3, γ = {γ 0,1 , γ 1,1 , γ 1,2 , γ 2,1 , γ 2,2 , γ 2,3 , γ 2,4 }. For a fixed integer L > 0, the random density associated with LDTFPL (α, σ 2 ) is defined as   2n ind. 0 −1 fz (e) = 2L φσ (e)pz {kσ (e)}, γ j,k ∼ Nq+1 0, (Z Z) (19) α(j + 1)2 with cdf kσ (e)  L X Gz (e) = pz {kσ (e)} 2 Φσ (e) − kσ (e) + pz (k),

(20)

k=1

˜ij s. Furthermore, where Z is the n × (q + 1) design matrix with mean-centered covariates z the LDTFP is specified by setting γ 0,1 ≡ 0, such that for every z ∈ X , Gz is almost surely a median-zero probability measure. This is important to avoid identifiability issues. As shown by Jara and Hanson (2011), the LDTFP has appealing theoretical properties such as

Journal of Statistical Software

21

continuity as a function of the covariates, large support on the space of conditional density functions, straightforward posterior computation relying on algorithms for fitting generalized linear models, and the process closely matches conventional Polya tree priors (see, e.g., Hanson 2006) at each value of the covariate, which justify its choice here.

3.2. MCMC ˜ v, τ 2 , σ 2 , γ, α) denote collectively the model parameters to be updated, where Let Ω = (yc , β, ˜ yc = {yij : aij < bij } are censored log-survival times. The yij ∈ yc , each component of β, vi and σ are all sampled using the single-variable slice sampling method (Neal 2003). For the LDTFP regression parameters γj,k , we utilize Metropolis-Hastings steps with Gaussian proposals based on iterative weighted least squares (Gamerman 1997), recognizing that the γj,k full conditionals are proportional to logistic regression likelihoods. The hyperparameters τ 2 and α are sampled according to their conjugate full conditional distributions. A complete description of updating steps is available in Zhou et al. (2017). The function frailtyGAFT sets the following hyperparameters as defaults: m0 = 0, S0 = 105 Ip+1 , a0 = b0 = 1, aτ = bτ = .001, and aσ = 2 + σ ˆ04 /(100ˆ v0 ), bσ = σ ˆ02 (aσ − 1), where 2 2 σ ˆ0 and vˆ0 are the estimates of σ and its asymptotic variance from fitting the parametric lognormal AFT model, respectively. Note here we assume a somewhat informative prior on σ 2 so that its mean is σ ˆ02 and variance is 100ˆ v0 . For the GRF prior, we again set aφ = 2 and bφ = (aφ − 1)/φ0 so that the prior of φ has mode at φ0 and the prior mean of 1/φ is 1/φ0 with infinite variance. Here φ0 satisfies ρ(s0 , s00 ; φ0 ) = 0.001, where ks0 − s00 k = maxij ksi − sj k. Again, the user-defined hyperparameters can be specified via the argument prior, e.g., for p = 3, L = 5, m0 = 0, S0 = 10Ip+1 , a0 = b0 = 1, and aσ = bσ = 2, the prior can be specified as below. > prior=list(maxL=5,m0=rep(0,4),S0=diag(10,4),siga0=1,sigb0=1,a0=1,b0=1) Given a set of posterior samples {Ω(s) , s = 1, . . . , S}, all the inference targets can be easily estimated. For example, the baseline survival function S0,z (t) = P (eβ0 + > t|z) given the covariate z is estimated by S  o 1 Xn (s) (s) S0,z (t) = , 1 − Gz log t − β0 S

(21)

s=1

(s)

where Gz (·) is given in (20) with all unknown parameters replaced by corresponding posterior values in the sth iterate.

3.3. Bayesian Hypothesis Testing The GAFT frailty model includes the following as important special cases: an AFT frailty model with nonparametric baseline where Gz = Gz0 for all z = z0 and parametric baseline model Gz = Φσ for all z ∈ X . Hypothesis tests can be constructed based on the LDTFP coefficients {γ l,k : k = 1, . . . , 2l , l = 1, . . . , L − 1}, where γ l,k = (γl,k,0 , . . . , γl,k,q )0 . Let γ l,k,−j denote the subvector of γ l,k without element γl,k,j for j = 0, . . . , q. Set Υj = (γl,k,j , k = 1, . . . , 2l , l = 1, . . . , L − 1)0 , Υ−j = (γ 0l,k,−j , k = 1, . . . , 2l , l = 1, . . . , L − 1)0 and Υ = (γ 0l,k , k = 1, . . . , 2l , l = 1, . . . , L − 1)0 . Testing the hypotheses H0 : Υ−0 = 0 and H0 : Υ = 0 leads

22

spBayesSurv, version 1.1.1

to global comparisons of the proposed model with the above two special cases respectively. Similarly, we may also test the null hypothesis H0 : Υj = 0 for the jth covariate effect of z on the baseline survival, j = 1, . . . , q. Suppose we wish to test H0 : Υj = 0 versus H1 : Υj 6= 0, for fixed j ∈ {1, . . . , q}. Following Zhou et al. (2017), the Bayes factor between hypotheses H1 and H0 can be approximated by L−1 2l YY

ˆ 10 = BF

l=1 k=1

 N 0 0,

2n (Z0 Z)−1 jj α ˆ (l + 1)2



ˆj) ˆ j, S N2L −2 (Υj = 0; m

,

(22)

where Np (·; m, S) denotes a p-variate normal density with mean m and covariance matrix S, ˆ j are the sample mean and covariance for Υj . ˆ j and S and m

3.4. Leukemia Survival Data The code below is used to fit the GAFT model with ICAR frailties for the leukemia survival data. As suggested by Zhou et al. (2017), the gamma prior Γ(a0 = 5, b0 = 1) is used for α. We include all four covariates in modeling the baseline survival function. > set.seed(1) > mcmc=list(nburn=5000, nsave=2000, nskip=4, ndisplay=1000); > prior=list(maxL=4, a0=5, b0=1); > ptm res1 = frailtyGAFT(formula=Surv(time,cens)~age+sex+wbc+tpi + +baseline(age,sex,wbc,tpi)+frailtyprior("car",district), + data=d,mcmc=mcmc,prior=prior,Proximity=E); scan = 1000 scan = 2000 > sfit1=summary(res1); sfit1 Generalized accelerated failure time frailty model: Call: frailtyGAFT(formula = Surv(time, cens) ~ age + sex + wbc + tpi + baseline(age, sex, wbc, tpi) + frailtyprior("car", district), data = d, mcmc = mcmc, prior = prior, Proximity = E) Posterior inference of regression Mean Median intercept 8.814068 8.854485 age -0.054063 -0.054041 sex -0.299306 -0.317065 wbc -0.004581 -0.004553 tpi -0.060635 -0.062607

coefficients Std. Dev. 95%HPD-Low 95%HPD-Upp 0.346621 8.097035 9.401137 0.004926 -0.063937 -0.045553 0.145519 -0.531467 0.030991 0.001457 -0.007829 -0.001803 0.021067 -0.100791 -0.019597

Posterior inference of scale parameter Mean Median Std. Dev. 95%HPD-Low scale 2.10578 2.09632 0.09638 1.93813

95%HPD-Upp 2.30722

Journal of Statistical Software

sex

wbc

1500

0.0 500

1500

0

500

1500

alpha

5

0.6 0.0

0.4

10

0.6

0.2

15

0.8

1.0

tau^2

0.2

−0.010 −0.008 −0.006 −0.004 −0.002

0.8

−0.2 −0.4 0

tpi

age=49 age=65 age=74

0.4

500

Survival Probability

0

−0.6

8.0

8.5

9.0

−0.065 −0.060 −0.055 −0.050 −0.045

1.0

9.5

age

23

0 0

500

1500

0

500

(a)

1500

0

500

1500

1000

2000

3000

4000

−0.53

5000

0

0.53

Time (days)

(b)

(c)

Figure 5: Leukemia survival data. GAFT model with ICAR frailties. (a) Trace plots for β, τ 2 and α. (b) Survival curves with 95% credible interval bands for female patients with wbc=38.59 and tpi=0.3398 at different ages. (c) Map for the negative posterior mean frailties; larger values mean higher mortality rate overall.

Posterior inference of precision parameter of LDTFP Mean Median Std. Dev. 95%HPD-Low 95%HPD-Upp alpha 6.894 6.684 2.153 3.131 11.171 Posterior inference of conditional CAR frailty variance Mean Median Std. Dev. 95%HPD-Low 95%HPD-Upp variance 0.3126 0.2860 0.1283 0.1124 0.5664 Bayes factors for LDTFP covariate effects: intercept age sex wbc 0.5495 4.6231 1.2374 5.5556

tpi 0.5740

overall 1.6032

normality 103.1727

Log pseudo marginal likelihood: LPML=-5939.093 Number of subjects:=1043 > systime1=proc.time()-ptm; systime1; user system elapsed 505.052 0.606 506.547 The Bayes factors for testing age and wbc effects on LDTFP are 4.6 and 1.6, respectively, indicating that the baseline survival function under the AFT model depends on age and wbc, and thus GAFT should be considered. The trace plots, survival curves and frailty map (Figure 5) can be obtained using the code similarly to Section 2.4. The only difference is that we need to specify the baseline covariates for plotting survival curves by including the argument xtfpred=xpred into the plot function. We see that the mixing for covariate effects is poor due to the non-smoothness of Polya trees. In this case, we need to run a much longer chain with higher thinning. > estimates=plot(res1, xpred=xpred, xtfpred=xpred, tgrid=tgrid);

24

spBayesSurv, version 1.1.1

4. Survival Models via Spatial Copulas Currently the package only supports spatial copula models for georeferenced (without replication, i.e. ni = 1), right-censored spatial data. Suppose subjects are observed at n distinct spatial locations s1 , . . . , sn . Let ti be a random event time associated with the subject at si and xi be a related p-dimensional vector of covariates, i = 1, . . . , n. For right-censored data, we only observe toi and a censoring indicator δi for each subject, where δi equals 1 if toi = ti and equals 0 if ti is censored at toi . Therefore, the observed data will be D = {(toi , δi , xi , si ); i = 1, . . . , n}. Note although the models below are developed for spatial survival data, non-spatial data are also accommodated. The use of copulas in the spatial context was first proposed by B´ardossy (2006), where the empirical variogram is replaced by empirical copulas to investigate the spatial dependence structure. Copulas completely describe association among random variables separately from their univariate distributions and thus capture joint dependence without the influence of the marginal distribution (Li 2010). In the context of survival models, the idea of spatial copula approach is to first assume that the survival time ti at location si marginally follows a model Sxi (t), then model the joint distribution of (t1 , . . . , tn )0 as P (t1 ≤ a1 , . . . , tn ≤ an ) = C(Fx1 (a1 ), . . . , Fxn (an )),

(23)

where Fxi (t) = 1 − Sxi (t) is the cumulative distribution function and the function C is an n-copula used to capture spatial dependence. The current package assumes a spatial version of the Gaussian copula (Li 2010), defined as  C(u1 , . . . , un ) = Φn Φ−1 {u1 }, . . . , Φ−1 {un }; R ,

(24)

where Φn (·, . . . , ·; R) denotes the distribution function of Nn (0, R). To allow for a nugget effect, we consider R[i, j] = θ1 ρ(si , sj ; θ2 )+(1−θ1 )I(si = sj ), where ρ(si , sj ; θ2 ) = exp{−θ2 ksi − sj k}. Here θ1 ∈ [0, 1], also known as a “partial sill” in Waller and Gotway (2004), is a scale parameter measuring a local maximum correlation, and θ2 controls the spatial decay over distance. Note that all the diagonal elements of R are ones, so it is also a correlation matrix. Under the above spatial Gaussian copula, the likelihood function based on upon the complete data {(ti , xi , si ), i = 1, . . . , n} is L = |R|

−1/2

Y n 1 0 −1 exp − z (R − In )z fxi (ti ), 2 

(25)

i=1

where zi = Φ−1 {Fxi (ti )} and fxi (t) is the density function corresponding to Sxi (t). We next discuss two marginal spatial survival models for Sxi (t) that are accommodated in the package. Note that for large n, the FSA introduced in Section 2.1 (with  replaced by 1 − θ1 ) can be applied.

4.1. Proportional Hazards Model via Spatial Copulas Assume that ti |xi marginally follows the proportional hazards (PH) model with cdf n o 0 Fxi (t) = 1 − exp −Λ0 (t)exi β

(26)

Journal of Statistical Software

25

and density n o 0 0 fxi (t) = exp −Λ0 (t)exi β λ0 (t)exi β , where β is aR p × 1 vector of regression coefficients, λ0 (t) is the baseline hazard function t and Λ0 (t) = 0 λ0 (s)ds is the cumulative baseline hazard function. The piecewise exponential model provides a flexible framework to deal with the baseline hazard (e.g. Walker and Mallick 1997). We partition the time period R+ into M intervals, say Ik = (dk−1 , dk ], k = 1, . . . , M , k where d0 = 0 and dM = ∞. Specifically, we set dk to be the M th quantile of the empirical distribution of the observed survival times for k = 1, . . . , M − 1. The baseline hazard is then assumed to be constant within each interval, i.e.

λ0 (t) =

M X

hk I{t ∈ Ik },

k=1

where hk s are unknown hazard values. Consequently, the cumulative baseline hazard function can be written as M (t)

Λ0 (t) =

X

hk ∆k (t),

k=1

where M (t) = min{k : dk ≥ t} and ∆k (t) = min{dk , t} − dk−1 . After incorporating spatial dependence via the copula in (24), the spCopulaCoxph function considers the following prior distributions: β ∼ Np (β 0 , S0 ), iid

hk |h ∼ Γ(r0 h, r0 ), k = 1, . . . , M,

(27)

(θ1 , θ2 ) ∼ Beta(θ1a , θ1b ) × Γ(θ2a , θ2b ) The spCopulaCoxph function sets the following default hyperparameter values: M = 10, ˆ β = 0, S0 = 105 Ip , θ1a = θ1b = θ2a = θ2b = 1, where h ˆ is the maximum r0 = 1, h = h, 0 likelihood estimate of the rate parameter from fitting an exponential PH model. A function indeptCoxph is also provided to fit the non-spatial standard PH model with above baseline and prior settings.

4.2. Bayesian Nonparametric Survival Model via Spatial Copulas We assume that yi = log ti given xi marginally follows a LDDPM model (De Iorio et al. 2009) with cdf,   Z log t − x0i β dG{β, σ 2 }, (28) Fxi (t) = Φ σ where Φ(·) is the cdf of the standard normal, and G follows the Dirichlet Process (DP) prior. This Bayesian nonparametric model treats the conditional distribution Fx as a function-valued parameter and allows its variance, skewness, modality and other features to flexibly vary with the x covariates. After incorporating spatial dependence via the copula in (24), the function

26

spBayesSurv, version 1.1.1

spCopulaDDP assumes the following prior distributions: G=

N X

wk δ(βk ,σ2 ) , wk = Vk

k−1 Y

(1 − Vj ), V0 = 0, VN = 1

k

k=1

j=0

iid

Vk ∼ Beta(1, α), k = 1, . . . , N, α ∼ Γ(a0 , b0 )

(29)

iid

β k |µ ∼ Np (µ, Σ), k = 1, . . . , N, µ ∼ Np (m0 , S0 ) iid

σk−2 |Σ ∼ Γ(νa , νb ), k = 1, . . . , N, Σ−1 ∼ Wp (κ0 Σ0 )−1 , κ0



(θ1 , θ2 ) ∼ Beta(θ1a , θ1b ) × Γ(θ2a , θ2b ). The following default hyperpriors are considered in spCopulaDDP: a0 = b0 = 2, νa = 3, ˆ S0 = Σ, ˆ and ˆ Σ0 = 30Σ, ˆ and κ0 = 7, where β νb = σ ˆ 2 , θ1a = θ1b = θ2a = θ2b = 1, m0 = β, 2 2 σ ˆ are the maximum likelihood estimates of β and σ from fitting the log-normal accelerated ˆ is the asymptotic covariance failure time model log(ti ) = x0i β + σi , i ∼ N (0, 1), and Σ ˆ estimate for β. A function indeptDDP is also provided to fit the non-spatial LDDPM model in (28) with above prior settings.

4.3. Leukemia Survival Data PH model with spatial copula The following code is used to fit the piecewise exponential PH model (26) with the Gaussian spatial copula (24) using M = 20 and default priors. We consider K = 100 and B = 1043 for the number of knots and blocks in the FSA of R. The total running time is 15445 seconds. > set.seed(1) > mcmc=list(nburn=5000, nsave=2000, nskip=4, ndisplay=1000); > prior=list(M=20, nknots=100, nblock=1043); > ptm res1 = spCopulaCoxph(formula=Surv(time,cens)~age+sex+wbc+tpi,data=d, + mcmc=mcmc,prior=prior, + Coordinates=cbind(d$xcoord,d$ycoord)); > sfit1=summary(res1); sfit1 Spatial Copula Cox PH model with piecewise constant baseline hazards Call: spCopulaCoxph(formula = Surv(time, cens) ~ age + sex + wbc + tpi, data = d, mcmc = mcmc, prior = prior, Coordinates = cbind(d$xcoord, d$ycoord)) Posterior inference of regression coefficients (Adaptive M-H acceptance rate: 0.2501): Mean Median Std. Dev. 95%CI-Low age 0.0277864 0.0278065 0.0019297 0.0240332 sex 0.0522938 0.0527421 0.0588919 -0.0625843 wbc 0.0027808 0.0027899 0.0003767 0.0020071 tpi 0.0257918 0.0257969 0.0081385 0.0087972

95%CI-Upp 0.0315580 0.1662136 0.0034546 0.0411955

Journal of Statistical Software sex

−0.1

0.025

0.2

0.035

age

27

500

0.0040

0

1000

1500

2000

0

500

1000

1500

2000

1500

2000

1500

2000

tpi

0.0015

0.00 0.03

wbc

0

500

1000

1500

2000

0

500

0.0

0.05

1.5

0.25

1000

range

3.0

partial sill

0

500

1000

1500

2000

0

500

1000

Figure 6: Leukemia survival data. Trace plots for β, θ1 and θ2 under the PH model with spatial copula.

Posterior inference of spatial sill and range parameters (Adaptive M-H acceptance rate: 0.2112): Mean Median Std. Dev. 95%CI-Low 95%CI-Upp sill 0.23051 0.23352 0.05587 0.10222 0.32903 range 0.41801 0.34165 0.34272 0.03715 1.31802 Log pseudo marginal likelihood: LPML=-5929.357 Number of subjects: n=1043 > systime1=proc.time()-ptm; systime1; user system elapsed 15262.274 177.716 15444.913 The trace plots (Figure 6) and survival curves (Figure 7, panel a) can be obtained using the code similarly to Section 2.4, where the only difference is that we also present the trace plots for partial sill θ1 and range θ2 . > traceplot(mcmc(res1$theta[1,]), xlab="", main="partial sill") > traceplot(mcmc(res1$theta[2,]), xlab="", main="range") Note that the higher the value of zi = Φ−1 {Fxi (ti )} is, the longer the survival time ti (i.e. lower mortality rate) would be. The posterior sample of zi s is saved in res1$Zpred. The following code is used to show the posterior mean of zi values on the map (Figure 7, panel b). > > > > > >

frail= round((rowMeans(res1$Zpred)),3); nclust=5; frail.cluster = cut(frail, breaks = nclust); frail.names = names(table(frail.cluster)) rbPal plot(nwengland) > points(cbind(d$xcoord,d$ycoord), col=frail.colors) > legend("topright",title="z values",legend=frail.names, + col=rbPal(nclust),pch=20, cex=1.7)

LDDPM model with spatial copula The following code is used to fit the LDDPM model (28) with the Gaussian spatial copula (24) using N = 10 and default priors. For the FSA, K = 100 and B = 1043 are used. The total running time is 20056 seconds. Note there is no summary output as before, as we are fitting a nonparametric model. > > > > > + + >

set.seed(1) mcmc=list(nburn=5000, nsave=2000, nskip=4, ndisplay=1000); prior=list(N=10, nknots=100, nblock=1043); ptm sum(log(res1$cpo)); ## LPML $ [1] -5931.5 The trace plots, survival curves, and map of zi s (Figure 8) can be obtained using the same code used for the PH copula model, where the difference is that we only present the trace plots for partial sill θ1 and range θ2 .

Journal of Statistical Software

29

partial sill 0.25

1.0

z values ●



age=49 age=65 age=74

500

1000

1500

2000

1500

2000

2

0.6 0.0

4

0.2

6

8

range

0.4

0

Survival Probability

0.00

0.05

0.10

0.8

0.15

0.20

● ●

0

0 0

500

1000

(a)

1000

2000

3000

4000



● ● ● ● ● ● ●● ● ●● ● ● ● ● ●●● ● ● ● ● ● ●● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ● ● ●● ● ● ●

● ● ●



(−0.172,−0.107] (−0.107,−0.0428] (−0.0428,0.0218] (0.0218,0.0864] (0.0864,0.151]

● ● ●● ● ●●● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ●● ● ● ● ● ● ● ● ●●● ●● ● ● ●● ● ● ● ● ●● ●●●● ● ● ● ● ●● ● ● ●●● ● ● ● ● ● ● ● ●● ● ●● ● ● ● ● ●● ● ● ●● ●● ● ● ●● ● ● ●● ● ●● ● ● ●● ● ●● ●● ● ● ● ● ● ● ● ● ● ● ● ●● ● ●● ● ●● ●● ● ● ● ● ●●● ● ● ●● ● ●● ● ● ● ●● ●●● ●● ● ● ● ●● ●● ● ● ● ● ●● ● ● ● ●●● ●●● ● ● ● ● ● ● ● ●● ● ● ● ●●● ● ● ●● ● ● ●● ● ●● ● ● ●●● ● ● ● ●●● ● ● ● ● ● ● ●● ● ● ● ●● ● ●●● ●● ● ● ● ● ● ● ● ● ● ● ● ● ●● ● ● ● ●● ●● ● ●● ●● ● ● ● ● ● ●● ● ● ● ● ● ●● ● ● ● ● ● ●● ● ● ●● ●●● ● ● ● ● ● ● ● ● ● ● ●●● ● ●● ● ● ●● ● ● ●● ●● ● ● ● ● ● ● ● ●● ●● ● ●● ●● ● ● ● ● ● ● ●●● ●● ● ● ●● ● ● ●● ● ● ● ●●●● ●●● ● ● ● ● ● ●●● ●●●● ● ● ● ●● ●● ●● ● ● ● ● ● ●● ● ● ●● ●● ● ● ●●●● ● ● ● ● ●●●● ● ●● ● ● ● ●● ●● ● ● ● ●● ● ●● ● ●● ● ● ● ●● ●●● ●● ●● ● ● ● ●● ● ● ● ● ● ● ●● ● ●● ●● ● ● ● ●●● ● ● ●● ●● ● ● ● ●●● ●● ● ● ● ● ● ● ● ●● ●● ● ● ● ●●●●● ●● ●● ● ● ● ●●● ●●●●● ● ● ● ● ● ● ●● ●● ●●● ● ● ●● ● ● ●●●● ●●● ●● ● ● ●● ● ● ●● ● ●●●● ● ● ● ● ●● ●● ●● ●● ● ● ●● ●● ● ●● ●●●● ● ●●● ●● ●●● ● ●● ●● ● ● ● ●● ● ● ●● ● ● ● ● ●● ●●● ● ● ● ●● ● ●● ● ● ● ● ●●● ●●●● ● ●● ●● ● ●● ●● ● ● ● ● ● ● ●● ●● ●●●● ●● ● ● ● ● ●● ●● ● ● ●●●●●●●● ● ● ● ●● ● ●● ● ● ● ● ● ● ● ● ● ● ● ● ● ●●● ●● ● ● ● ●● ●● ● ● ●● ●● ● ● ● ● ● ● ● ●● ● ●● ●● ● ● ●● ● ●●● ● ● ● ●●●● ●●● ● ● ●●● ● ● ●● ● ●● ● ● ● ●●● ●

5000

Time (days)

(b)

(c)

Figure 8: Leukemia survival data. LDDPM model with spatial copula. (a) Trace plots for partial sill θ1 and range θ2 . (b) Survival curves with 95% credit interval bands for female patients with wbc=38.59 and tpi=0.3398 at different ages. (c) Map for the posterior mean of zi values; smaller z values mean higher mortality rate overall.

5. Conclusions There is a wealth of R packages for non-spatial survival data, starting with survival (Therneau 2015), included with all base installs of R. The survival package fits (discretely) stratified semiparametric PH models to right-censored data with exchangeable gamma frailties, as well as left-truncated data, time-dependent covariates, etc. Parametric log-logistic, Weibull and lognormal AFT models can also be fit by this package. From there, there are many packages for various models and types of censoring; a partial review discussing several available R packages is given by Zhou and Hanson (2015); also see Zhou and Hanson (2017). In comparison there are very few R packages for spatially correlated survival data, with the notable exceptions of R2BayesX and spatsurv, both of which focus on PH exclusively. The spBayesSurv package allows the routine fitting of several popular semiparametric and nonparametric models to spatial survival data. Although examples were not provided here, spBayesSurv can also handle non-spatial survival data using either exchangeable Gaussian or no frailty models. Another unintroduced function is survregbayes2 which implements the Polya tree based PH, PO, and AFT models of Hanson (2006) and Zhao, Hanson, and Carlin (2009) for areally-referenced data. As pointed out in these papers, MCMC mixing for Polya tree models can be highly problematic when the true baseline survival function is very different from the parametric family that centers the Polya tree; the TBP prior provides much improved MCMC mixing with essentially the same quality of fit as Polya trees. Future additions to spBayesSurv include spatial copula (both georeferenced and areal) versions of the PH, PO, and AFT models using TBP priors, as well as continuously-stratified proportional hazards and proportional odds models. An extension of all semiparametric models to additive linear structure, which is already incorporated into BayesX, is also planned.

References

30

spBayesSurv, version 1.1.1

Antoniak CE (1974). “Mixtures of Dirichlet processes with applications to Bayesian nonparametric problems.” Annals of Statistics, 2, 1152–1174. Arbia G, Espa G, Giuliani D, Micciolo (2016). “A spatial analysis of health and pharmaceutical firm survival.” Journal of Applied Statistics, p. in press. Banerjee S, Carlin BP, Gelfand AE (2014). Hierarchical Modeling and Analysis for Spatial Data, Second Edition. Chapman and Hall/CRC Press. Banerjee S, Dey DK (2005). “Semiparametric proportional odds models for spatially correlated survival data.” Lifetime Data Analysis, 11(2), 175–191. Banerjee S, Gelfand AE, Finley AO, Sang H (2008). “Gaussian predictive process models for large spatial data sets.” Journal of the Royal Statistical Society: Series B (Statistical Methodology), 70(4), 825–848. B´ardossy A (2006). “Copula-based geostatistical models for groundwater quality parameters.” Water Resources Research, 42(11), 1–12. Belitz C, Brezger A, Klein N, Kneib T, Lang S, Umlauf N (2015). BayesX - Software for Bayesian inference in structured additive regression models. Version 3.0. Available from http://www.bayesx.org. Besag J (1974). “Spatial interaction and the statistical analysis of lattice systems.” Journal of the Royal Statistical Society: Series B, 36(2), 192–236. Chen Y, Hanson T, Zhang J (2014). “Accelerated hazards model based on parametric families generalized with Bernstein polynomials.” Biometrics, 70(1), 192–201. Chiou SH, Kang S, Yan J (2015). “Semiparametric accelerated failure time modeling for clustered failure times from stratified sampling.” Journal of the American Statistical Association, 110(510), 621–629. Cox DR, Oakes D (1984). Analysis of Survival Data. Chapman & Hall: London. Cox DR, Snell EJ (1968). “A general definition of residuals.” Journal of the Royal Statistical Society. Series B (Methodological), 30(2), 248–275. Darmofal D (2009). “Bayesian spatial survival models for political event processes.” American Journal of Political Science, 53(1), 241–257. ISSN 1540-5907. De Iorio M, Johnson WO, M¨ uller P, Rosner GL (2009). “Bayesian nonparametric nonproportional hazards survival modeling.” Biometrics, 65(3), 762–771. Finley AO, Sang H, Banerjee S, Gelfand AE (2009). “Improving the performance of predictive process modeling for large datasets.” Computational Statistics & Data Analysis, 53(8), 2873–2884. Gamerman D (1997). “Sampling from the posterior distribution in generalized linear mixed models.” Statistics and Computing, 7(1), 57–68. Geisser S, Eddy WF (1979). “A Predictive approach to model selection.” Journal of the American Statistical Association, 74(365), 153–160.

Journal of Statistical Software

31

Haario H, Saksman E, Tamminen J (2001). “An adaptive Metropolis algorithm.” Bernoulli, 7(2), 223–242. Hanson T, Johnson W, Laud P (2009). “Semiparametric inference for survival models with step process covariates.” Canadian Journal of Statistics, 37(1), 60–79. Hanson TE (2006). “Inference for mixtures of finite Polya tree models.” Journal of the American Statistical Association, 101(476), 1548–1565. Hanson TE, Branscum AJ, Johnson WO (2014). “Informative g-priors for logistic regression.” Bayesian Analysis, 9(3), 597–612. Henderson R, Shimakura S, Gorst D (2002). “Modeling spatial variation in leukemia survival data.” Journal of the American Statistical Association, 97(460), 965–972. Hennerfeind A, Brezger A, Fahrmeir L (2006). “Geoadditive survival models.” Journal of the American Statistical Association, 101(475), 1065–1075. Jara A, Hanson TE (2011). “A class of mixtures of dependent tailfree processes.” Biometrika, 98(3), 553–566. Johnson ME, Moore LM, Ylvisaker D (1990). “Minimax and maximin distance designs.” Journal of statistical planning and inference, 26(2), 131–148. Kammann EE, Wand MP (2003). “Geoadditive models.” Applied Statistics, 52, 1–18. Kneib T (2006). “Mixed model-based inference in geoadditive hazard regression for intervalcensored survival times.” Computational Statistics & Data Analysis, 51(2), 777–792. Kneib T, Fahrmeir L (2007). “A mixed model approach for geoadditive hazard regression.” Scandinavian Journal of Statistics, 34(1), 207–228. Konomi BA, Sang H, Mallick BK (2014). “Adaptive Bayesian nonstationary modeling for large spatial datasets using covariance approximations.” Journal of Computational and Graphical Statistics, 23, 802–929. Kuo L, Mallick B (1998). “Variable selection for regression models.” Sankhy¯ a: The Indian Journal of Statistics, Series B, 60, 65–81. Lavine M (1992). “Some aspects of Polya tree distributions for statistical modelling.” The Annals of Statistics, 20, 1222–1235. Li J (2010). Application of Copulas as a New Geostatistical Tool. Ph.D. thesis, Institut f¨ ur Wasser- und Umweltsystemmodellierung. Li J, Hong Y, Thapa R, Burkhart HE (2015a). “Survival analysis of loblolly pine trees with spatially correlated random effects.” Journal of the American Statistical Association, 110(510), 486–502. Li L, Hanson T, Zhang J (2015b). “Spatial extended hazard model with application to prostate cancer survival.” Biometrics, 71(2), 313–322.

32

spBayesSurv, version 1.1.1

Li Y, Lin X (2006). “Semiparametric normal transformation models for spatially correlated survival data.” Journal of the American Statistical Association, 101(474), 591–603. M¨ uller P, Quintana F, Jara A, Hanson T (2015). Bayesian Nonparametric Data Analysis. Springer-Verlag: New York. Nardi A, Schemper M (2003). “Comparing Cox and parametric models in clinical studies.” Statistics in Medicine, 22(23), 3597–3610. Neal RM (2003). “Slice sampling.” Annals of Statistics, 31(3), 705–767. Sang H, Huang JZ (2012). “A full scale approximation of covariance functions for large spatial data sets.” Journal of the Royal Statistical Society: Series B (Statistical Methodology), 74(1), 111–132. Spiegelhalter DJ, Best NG, Carlin BP, Van Der Linde A (2002). “Bayesian measures of model complexity and fit.” Journal of the Royal Statistical Society, Series B, 64(4), 583–639. Taylor BM (2015). “Auxiliary variable Markov Chain Monte Carlo for spatial survival and geostatistical models.” arXiv preprint arXiv:1501.01665. Taylor BM (2017). “Spatial modelling of emergency service response times.” Journal of the Royal Statistical Society: Series A (Statistics in Society), 180(2), 433–453. Taylor BM, Rowlingson BS (2017). “spatsurv: an R package for Bayesian inference with spatial survival models.” Journal of Statistical Software, 77(4), 1–32. Therneau T, Crowson C, Atkinson E (2017). Using time dependent covariates and time dependent coefficients in the Cox model. URL http://cran.es.r-project.org/web/packages/ survival/vignettes/timedep.pdf. Therneau TM (2015). A Package for Survival Analysis in S. Version 2.38, URL https: //CRAN.R-project.org/package=survival. Turnbull BW (1974). “Nonparametric estimation of a survivorship function with doubly censored data.” Journal of the American Statistical Association, 69(345), 169–173. Umlauf N, Adler D, Kneib T, Lang S, Zeileis A (2015). “Structured additive regression models: An R interface to BayesX.” Journal of Statistical Software, 63(21), 1–46. Verdinelli I, Wasserman L (1995). “Computing Bayes factors using a generalization of the Savage-Dickey density ratio.” Journal of the American Statistical Association, 90(430), 614–618. Walker SG, Mallick BK (1997). “Hierarchical generalized linear models and frailty models with Bayesian nonparametric mixing.” Journal of the Royal Statistical Society, Series B: Methodological, 59, 845–860. Waller LA, Gotway CA (2004). Applied spatial statistics for public health data. John Wiley & Sons.

Journal of Statistical Software

33

Wang S, Zhang J, Lawson AB (2012). “A Bayesian normal mixture accelerated failure time spatial model and its application to prostate cancer.” Statistical Methods in Medical Research, http://dx.doi.org/10.1177/0962280212466189. Zhao L, Hanson TE, Carlin BP (2009). “Mixtures of Polya trees for flexible spatial frailty survival modelling.” Biometrika, 96(2), 263–276. Zhou H, Hanson T (2015). “Bayesian spatial survival models.” In Nonparametric Bayesian Inference in Biostatistics, pp. 215–246. Springer. Zhou H, Hanson T (2017). “A unified framework for fitting Bayesian semiparametric models to arbitrarily censored spatial survival data.” arXiv preprint arXiv:1701.06976. Zhou H, Hanson T, Jara A, Zhang J (2015a). “Modeling county level breast cancer survival data using a covariate-adjusted frailty proportional hazards model.” The Annals of Applied Statistics, 9(1), 43–68. Zhou H, Hanson T, Knapp R (2015b). “Marginal Bayesian nonparametric model for time to disease arrival of threatened amphibian populations.” Biometrics, 71(4), 1101–1110. Zhou H, Hanson T, Zhang J (2017). “Generalized accelerated failure time spatial frailty model for arbitrarily censored data.” Lifetime Data Analysis, in press.

Affiliation: Haiming Zhou Division of Statistics Northern Illinois University E-mail: [email protected] URL: http://niu.edu/stat/people/faculty/Zhou.shtml

Journal of Statistical Software published by the Foundation for Open Access Statistics MMMMMM YYYY, Volume VV, Issue II doi:10.18637/jss.v000.i00

http://www.jstatsoft.org/ http://www.foastat.org/ Submitted: yyyy-mm-dd Accepted: yyyy-mm-dd