Description Usage Arguments Details Author(s) Examples
View source: R/user_utilities.R
Gets probability or quantile estimates from a ic_sp
, ic_par
or ic_bayes
object.
Provided estimates conditional on regression parameters found in newdata
.
1  getFitEsts(fit, newdata, p, q)

fit 
model fit with 
newdata 

p 
Percentiles 
q 
Quantiles 
For the ic_sp
and ic_par
, the MLE estimate is returned. For ic_bayes
,
the MAP estimate is returned. To compute the posterior means, use sampleSurv
.
If newdata
is left blank, baseline estimates will be returned (i.e. all covariates = 0).
If p
is provided, will return the estimated F^1(p  x). If q
is provided,
will return the estimated F(q  x). If neither p
nor q
are provided,
the estimated conditional median is returned.
In the case of ic_sp
, the MLE of the baseline survival is not necessarily unique,
as probability mass is assigned to disjoint Turnbull intervals, but the likelihood function is
indifferent to how probability mass is assigned within these intervals. In order to have a well
defined estimate returned, we assume probability is assigned uniformly in these intervals.
In otherwords, we return *a* maximum likelihood estimate, but don't attempt to characterize *all* maximum
likelihood estimates with this function. If that is desired, all the information needed can be
extracted with getSCurves
.
Clifford AndersonBergman
1 2 3 4 5 6 7 8 9 10  simdata < simIC_weib(n = 500, b1 = .3, b2 = .3,
inspections = 6, inspectLength = 1)
fit < ic_par(Surv(l, u, type = 'interval2') ~ x1 + x2,
data = simdata)
new_data < data.frame(x1 = c(1,2), x2 = c(1,1))
rownames(new_data) < c('grp1', 'grp2')
estQ < getFitEsts(fit, new_data, p = c(.25, .75))
estP < getFitEsts(fit, q = 400)

Loading required package: survival
Loading required package: Rcpp
Loading required package: coda
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.