confband {cotram} | R Documentation |
Confidence bands for transformation, distribution, survivor or cumulative hazard functions
confband(object, newdata, level = 0.95, ...) ## S3 method for class 'cotram' confband(object, newdata, level = 0.95, type = c("trafo", "distribution", "survivor", "cumhazard"), smooth = FALSE, q = NULL, K = 20, cheat = K, ...)
object |
an object of class |
newdata |
a data frame of observations. |
level |
the confidence level. |
type |
the function to compute the confidence band for. |
smooth |
logical; if |
q |
quantiles at which to evaluate the model. |
K |
number of grid points the function is evaluated at
(in the absence of |
cheat |
number of grid points the function is evaluated at when
using the quantile obtained for |
... |
additional arguments to |
The function is evaluated at the count response or at K
grid points
and simultaneous confidence intervals are then interpolated in order to
construct the band.
For each row in newdata
the function and corresponding confidence
band evaluated at the count response (or K
or cheat
grid points)
is returned.
data("birds", package = "TH.data") ### fit count transformation model with cloglog link m_birds <- cotram(SG5 ~ AOT + AFS + GST + DBH + DWC + LOG, data = birds, method = "cloglog") ### compute asymptotic confidence bands for the distribution function ### for the first oberservation confband(m_birds, newdata = birds[1, ], type = "distribution")