Description Usage Arguments Details Value Note Author(s) References See Also Examples
Estimate the parametric part of the CoxSEI model using (conditionally) right-censored counting process data.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | coxseiest(dat, par.init, m = 2, mit = 1000, tr = TRUE,
method = "L-BFGS-B", lower=c(rep(-Inf,ncol(dat)-3),-Inf,0),
upper=rep(Inf,ncol(dat)-3 + 2),
gfun = function(x, pa) {
ifelse(x <= 0, rep(0, length(x)), pa[1] * exp(-pa[2] * x))
})
coxseiest2(dat, par.init, m = 2, mit = 1000, tr = TRUE,
method = "L-BFGS-B", lower=c(rep(-Inf,ncol(dat)-3),-Inf,0),
upper=rep(Inf,ncol(dat)-3 + 2),
gfun = function(x, pa) {
ifelse(x <= 0, rep(0, length(x)), pa[1] * exp(-pa[2] * x))
})
coxseiest3(dat, par.init, m = 2, mit = 1000, tr = TRUE,
method = "L-BFGS-B", lower=c(rep(-Inf,ncol(dat)-3),-Inf,0),
upper=rep(Inf,ncol(dat)-3 + 2))
|
dat |
a data frame with columns |
par.init |
init guess of the value of the parameters to start the optimization iteration with. |
m |
order of "autoregression" of the excitation term. |
mit |
maximum number of iteration in the optimization routine |
tr |
if set to |
method |
method of optimization |
lower |
vector of lower boundary values of the parameter space |
upper |
vector of upper boundary of the parameter space |
gfun |
the excitation function. Defaults to the exponential decay function g(t;γ)=γ_1 γ_2 \exp (-γ_2 t) |
coxseiest
uses only R code; coxseiest2
uses external C
code, and is expected to be 3~4 times fasters than the former;
coxseiest3
assumes the excitation function is the exponential
function as defaulted by the former two, and hardwares it in the C
side of the code, and therefore is much faster than the former two
when the exponential excitation function is desired.
A list as that returned by the call to the optimizer routine. For instance,
par |
gives the estimate of the parameters |
hessian |
gives the inverse of the estimate of the variance-covariance matrix |
the excitation function has to contain exactly two parameters; a feature that does not seem desiable and might change later.
Feng Chen <feng.chen@unsw.edu.au>
Feng Chen and Kani Chen. (2014). Modeling Event Clustering Using the m-Memory Cox-Type Self-Exciting Intensity Model. International Journal of Statistics and Probability. 3(3): 126-137. doi:10.5539/ijsp.v3n3p126 URL: http://dx.doi.org/10.5539/ijsp.v3n3p126
Feng Chen and Kani Chen. (2014). Case-cohort analysis of clusters of recurrent events. 20(1): 1-15. doi: 10.1007/s10985-013-9275-3
See optim
for the components of the returned value
1 2 3 4 5 6 7 | data("dat")
## this takes over 15 minutes
##est0 <- coxseiest(dat,par.init=c(0.2,0.4,0.6,0.6,5))
## this one takes about 4 minutes
##est1 <- coxseiest2(dat,par.init=c(0.2,0.4,0.6,0.6,5))
## this one takes about 10 seconds
est2 <- coxseiest3(dat,par.init=c(0.2,0.4,0.6,0.6,5))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.