confint.zyp | R Documentation |
Computes a confidence interval on a result from zyp.sen.
## S3 method for class 'zyp'
confint(object, parm, level = 0.95, ...)
object |
an object of class zyp, returned by zyp.sen. |
parm |
unused; for compatibility with confint. |
level |
the confidence level to compute a confidence interval at. |
... |
additional unused arguments. |
This routine computes a confidence interval on the slope and intercept of the result returned by zyp.sen. The confidence interval on the slope is calculated using the method defined in (Sen, 1968).
The confidence interval on the intercept is computed by taking the standard deviation of the intercepts (sd.i), the z statistic for the given confidence level (z), and the mean (m). The confidence level is then:
c(m - z * sd.i, m + z * sd.i)
A matrix containing the upper and lower bounds of the intersect and slope, respectively.
zyp.trend.vector
, zyp-package.
x <- c(0, 1, 2, 4, 5)
y <- c(6, 4, 1, 8, 7)
slope <- zyp.sen(y~x)
ci <- confint.zyp(slope)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.