aftGL: Function to Fit the Penalized Parametric Bayesian Accelerated...

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/aftGL.R

Description

Penalized parametric Bayesian accelerated failure time model with group lasso prior is implemented to analyze survival data with high-dimensional covariates.

Usage

1
aftGL(Y, data, grpInx, hyperParams, startValues, mcmc)

Arguments

Y

a data.frame containing univariate time-to-event outcomes from n subjects. It is of dimension n\times 2: the columns correspond to y, δ.

data

a data.frame containing p covariate vectors from n subjects. It is of dimension n\times p.

grpInx

a vector of p group indicator for each variable

hyperParams

a list containing hyperparameter values in hierarchical models: (nu0, sigSq0): hyperparameters for the prior of σ^2; (alpha0, h0): hyperparameters for the prior of α; (rLam, deltaLam): hyperparameters for the prior of λ^2.

startValues

a list containing starting values for model parameters. See Examples below.

mcmc

a list containing variables required for MCMC sampling. Components include, numReps, total number of scans; thin, extent of thinning; burninPerc, the proportion of burn-in. See Examples below.

Value

aftGL returns an object of class aftGL.

Author(s)

Kyu Ha Lee, Sounak Chakraborty, (Tony) Jianguo Sun

References

Lee, K. H., Chakraborty, S., and Sun, J. (2017). Variable Selection for High-Dimensional Genomic Data with Censored Outcomes Using Group Lasso Prior. Computational Statistics and Data Analysis, Volume 112, pages 1-13.

See Also

VS

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# generate some survival data	
	set.seed(204542)
	
	p = 20
	n = 200
	logHR.true <- c(rep(4, 10), rep(0, (p-10)))	

	CovX<-matrix(0,p,p)

	for(i in 1:10){
		for(j in 1:10){
			CovX[i,j] <- 0.3^abs(i-j)
			}
		}
		
	diag(CovX) <- 1
	
	data	<- apply(rmvnorm(n, sigma=CovX, method="chol"), 2, scale)	
	pred <- as.vector(exp(rowSums(scale(data, center = FALSE, scale = 1/logHR.true))))
	
	t 		<- rexp(n, rate = pred)
	cen		<- runif(n, 0, 8)      
	tcen 		<- pmin(t, cen)
	di 		<- as.numeric(t <= cen)
	
	n <- dim(data)[1]
	p <- dim(data)[2]

	Y <- data.frame(cbind(tcen, di))
	colnames(Y) <- c("time", "event")

	grpInx <- 1:p
	K <- length(unique(grpInx))
	
	############################
	hyperParams <- list(nu0=3, sigSq0=1, alpha0=0, h0=10^6, rLam=0.5, deltaLam=2)

	############################
	startValues <- list(alpha=0.1, beta=rep(1,p), sigSq=1, tauSq=rep(0.4,p), lambdaSq=5,
	 				w=log(tcen))

	############################	
	mcmc <- list(numReps=100, thin=1, burninPerc=0.5)
	
	############################
	fit <- aftGL(Y, data, grpInx, hyperParams, startValues, mcmc)
## Not run:   
VS(fit, X=data)

## End(Not run)

psbcGroup documentation built on June 24, 2021, 9:08 a.m.

Related to aftGL in psbcGroup...