Interval: Prediction and confidence intervals for BAMSAUR

View source: R/Interval.R

IntervalR Documentation

Prediction and confidence intervals for BAMSAUR

Description

This function is built into the main BAMSAUR functions and can be used to calculate the prediction and confidence intervals for individual age-at-death estimates

Usage

Interval(wear, wear.data, interval, level, df, s)

Arguments

wear

The average wear score from an individual, or a vector containing multiple scores.

wear.data

A vector containing all the average wear scores from the sample used to create the age-at-death estimation equation.

interval

The type of interval required. Can be "prediction" or "confidence".

level

The level of the prediction or confidence interval. A number between 0 and 1 (not inclusive).

df

The residual degrees of freedom from the regression analysis.

s

Standard deviation of the fitted regression line.

Details

Calculation of age intervals is conducted using the formulas for the "confidence interval for the mean value of y for a given value of x", and "the prediction interval for an individual" (Altman and Garner 2000: 76-79)

Value

returns the age range (+- years) of the estimated age(s)-at-death.

References

Altman, D.G. and Gardner, M.J. (2000). Regression and correlation. In (eds) Altman, D. G., Machin, D., Bryant, T.N., and Gardner, M.J. (73-92). Statistics with Confidence(2nd ed.). BMJ Books.


bbartholdy/BAMSAUR documentation built on Jan. 14, 2024, 1:39 a.m.