life.table {mortAAR} | R Documentation |
Calculates a life table
Description
life.table
calculates
life table(s).
The algorithm is optimised for deceased populations
encountered in archaeological research.
See Chamberlain 2006, 27ff., Herrmann et. al 1990, 303ff.,
Kokkotidis/Richter 1991, Keyfitz et al. 2005
for selected literature.
The function takes an individual data.frame or a list of
data.frames and returns an object of class mortaar_life_table
or mortaar_life_table_list, for which specialised summary,
print and plot functions exist.
Usage
life.table(neclist, agecor = TRUE, agecorfac = c(), option_spline = NULL)
Arguments
neclist |
single data.frame or list of data.frames with the columns 'x', 'a', 'Dx'.
|
agecor |
logical, optional. If set TRUE, the average number of years lived within a given age class of individuals having died in this class can be adjusted via agecorfac. If set FALSE, it is assumed that they died in the middle of this class. Due to the higher mortality rates of infants, this assumption is certainly inaccurate for individuals <= 5 years. Default setup is: TRUE. |
agecorfac |
numeric vector, optional. Only applies if agecor == TRUE. Given values replace the standard values from the first age interval onward. Default setup is 1/3 for every age class <= 5 life years, and 1/2 for the others. |
option_spline |
integer, optional. If > 0, values for adults will be interpolated by a monotonic cubic spline. Usual options will by '10' or '20' which will interpolate the values for individuals of an age of 20 or older by 10- or 20- year cumulated values. To be used carefully, as diagnostic features of the life table might be smoothed and essentially removed. Only available when the methods 'Standard' or 'Equal5' in prep.life.table have been chosen. |
Value
An object of class mortaar_life_table or mortaar_life_table_list. Each mortaar_life_table contains the following variables:
-
x: age interval.
-
a: years within x.
-
Ax: average number of years lived by an individual that died within a specific age class x :
A_{x} = a_{x} * agecorfac_{x}
-
Dx: number of deaths within x.
-
dx: proportion of deaths within x (percent) :
d_{x} = \frac{D_{x}}{\sum_{i=1}^{n} D_{i}} * 100
-
lx: survivorship within x (percent) :
l_{x+1} = l_{x} - d_{x}
withl_{0} = 100
-
qx: probability of death within x (percent) :
q_{x} = \frac{d_{x}}{l_{x}}* 100
-
Lx: number of years lived within x by those that died within x and those that reached the next age class :
L_{x} = (a_{x} * l_{x}) - ((a_{x} - A_{x}) * d_{x})
-
Tx: sum of years lived within current and remaining x :
T_{x+1} = T_{x} - L_{x}
withT_{0} = \sum_{i=1}^{n}{L_{i}}
-
ex: average years of life remaining (average life expectancy at mean(x)) :
e_{x} = \frac{T_{x}}{l_{x}}
-
rel_popx: percentage of L(x) of the sum of L(x) :
relpopx_{x} = \frac{L_{x}}{\sum_{i=1}^{n}{L_{i}}} * 100
References
Chamberlain AT (2006). Demography in archaeology, Cambridge Manuals in Archaeology. Cambridge University Press. https://doi.org/10.1017/CBO9780511607165.
Herrmann B, Grupe G, Hummel S, Piepenbrink H, Schutkowski H (1990). Praehistorische Anthropologie: Leitfaden der Feld- und Labormethoden. Springer, Berlin.
Keyfitz N, Caswell H (2005). Applied Mathematical Demography. Springer. https://link.springer.com/book/10.1007/b139042.
Kokkotidis KG, Richter J (1991). “Graeberfeld-Sterbetafeln.” Archaeologische Informationen. Mitteilungen zur Ur- und Fruehgeschichte, 14(2), 219–241.
Examples
# Create a mortaar_life_table from a prepared dataset.
schleswig_1 <- life.table(schleswig_ma[c("a", "Dx")])
print(schleswig_1)
plot(schleswig_1, display = "lx")
# Create a mortaar_life_table_list from two datasets.
odagsen <- life.table(list(
"corpus mandibulae" = odagsen_cm[c("a", "Dx")],
"margo orbitalis" = odagsen_mo[c("a", "Dx")]
))
print(odagsen)
plot(odagsen, display = "ex")
# Prepare a real world dataset and create a mortaar_life_table.
library(magrittr)
magdalenenberg %>%
replace(. == "60-x", "60-70") %>%
tidyr::separate(a, c("from", "to")) %>%
dplyr::mutate(from = as.numeric(from), to = as.numeric(to)) %>%
prep.life.table(
dec = "Dx",
agebeg = "from",
ageend = "to",
method = "Standard",
agerange = "excluded"
) %>%
life.table()