Package 'petitr'

Title: Relative Growth Rate
Description: Calculates the relative growth rate (RGR) of a series of individuals by building a life table and solving the Lotka-Birch equation. (See Birch, L. C. 1948. The intrinsic rate of natural increase of an insect population. - Journal of Animal Ecology 17: 15-26) <doi:10.2307/1605>.
Authors: Jean-Sebastien Pierre <[email protected]>
Maintainer: Jean-Sebastien Pierre <[email protected]>
License: GPL (>= 2)
Version: 1.0
Built: 2025-02-28 04:00:35 UTC
Source: https://github.com/cran/petitr

Help Index


"Big" life table with 100 individuals

Description

a life table with 100 individuals to test the time required by jackknife estimation

Usage

data(grosdata)

Format

A data frame with 100 observations on the following 22 variables.

V1

fecundity of day 1

V2

fecundity of day 2

V3

fecundity of day 3

V4

fecundity of day 4

V5

fecundity of day 5

V6

fecundity of day 6

V7

fecundity of day 7

V8

fecundity of day 8

V9

fecundity of day 9

V10

fecundity of day 10

V11

fecundity of day 11

V12

fecundity of day 12

V13

fecundity of day 13

V14

fecundity of day 14

V15

fecundity of day 15

V16

fecundity of day 16

V17

fecundity of day 17

V18

fecundity of day 18

V19

fecundity of day 19

V20

fecundity of day 20

V21

fecundity of day 21

V22

fecundity of day 22

Details

fictitious data designed to check the time needed and the effect of the m parameter of the jackknife estimation

Source

J.S. Pierre, fictitious

Examples

data(grosdata)
petitr(grosdata)

life table for ten individuals

Description

Daily fecundity of ten individuals (fictitious data)

Usage

data(life)

Format

A data frame with 10 observations on the following 11 variables.

X1

numeric vector, age

X2

numeric vector, first individual

X3

numeric vector, second individual

X4

numeric vector, ...

X5

numeric vector, ...

X6

numeric vector, ...

X7

numeric vector, ...

X8

numeric vector, ...

X9

numeric vector, ...

X10

numeric vector, ...

X11

numeric vector, tenth individual

Details

the first columns stands for the age of the individual. must be sorted in ascending order and represent equal age classes.

Examples

data(life)
petitr(life)

life table for ten individuals

Description

Daily fecundity of ten individuals (fictitious data)

Usage

data(life1)

Format

A data frame with 10 observations on the following 11 variables.

X1

numeric vector, age

X2

numeric vector, first individual

X3

numeric vector, second individual

X4

numeric vector, ...

X5

numeric vector, ...

X6

numeric vector, ...

X7

numeric vector, ...

X8

numeric vector, ...

X9

numeric vector, ...

X10

numeric vector, ...

X11

numeric vector, tenth individual

Details

the first columns stands for the age of the individual. must be sorted in ascending order and represent equal age classes.

Examples

data(life1,life2,life3)
ranova(list(life1,life2,life3))

life2 table for ten individuals

Description

Daily fecundity of ten individuals (fictitious data)

Usage

data(life2)

Format

A data frame with 10 observations on the following 11 variables.

X1

numeric vector, age

X2

numeric vector, first individual

X3

numeric vector, second individual

X4

numeric vector, ...

X5

numeric vector, ...

X6

numeric vector, ...

X7

numeric vector, ...

X8

numeric vector, ...

X9

numeric vector, ...

X10

numeric vector, ...

X11

numeric vector, tenth individual

Details

the first columns stands for the age of the individual. must be sorted in ascending order and represent equal age classes.

Examples

data(life1,life2,life3)
ranova(list(life1,life2,life3))

life3 table for ten individuals

Description

Daily fecundity of ten individuals (fictitious data)

Usage

data(life3)

Format

A data frame with 10 observations on the following 11 variables.

X1

numeric vector, age

X2

numeric vector, first individual

X3

numeric vector, second individual

X4

numeric vector, ...

X5

numeric vector, ...

X6

numeric vector, ...

X7

numeric vector, ...

X8

numeric vector, ...

X9

numeric vector, ...

X10

numeric vector, ...

X11

numeric vector, tenth individual

Details

the first columns stands for the age of the individual. must be sorted in ascending order and represent equal age classes.

Examples

data(life1,life2,life3)
ranova(list(life1,life2,life3))

Per capita growth rate from individual data

Description

calculates the per capita growth rate of a series of individuals through the set of individual life tables

Usage

petitr(tabvie, niter = 100, eps = 1e-07, m = 1, alpha = 0.05, s = 1)

Arguments

tabvie

A data.frame with a first column recording the endpoint of age classes, and as many columns as individuals. For each individual, each row represents the number of offspring produced by the individual vetween age x-1 and age x. After death or after the end of reproductive life, each column must be filled by zeros . The last row represents therefore the maximum reproductive age observed in the data set. The number of columns is n+1, where n is the number of individuals.

niter

the maximum number of iterations for the Newton's method. Default is 100

eps

Precision required for the Newton's method. Default is 1e-07.

m

Size of the subsamples to drop one after one in the Jackknife method. Default is m=1. Any other value must divide exactly n,the number of individuals.

alpha

First kind error risk. Default is alpha=0.05.

s

ex ratio expressed as the proportion of females in the total population. Default is 1, meaning a parthenogenetic population (ex. aphids). For a sexual population one would often set s=0.5.

Details

Calls r, and xlxmx, called by ranova.

Value

a vector with the pseudovalues of r calculated by the jackknife method

Author(s)

Jean-Sebastien Pierre [email protected]

References

Birch, L. C. 1948. The intrinsic rate of natural increase of an insect population. - Journal of Animal Ecology 17: 15-26. Lotka, A. (1924). Elements of mathematical biology. Reprinted 1956 by Dover Publications Inc., New York, USA.

See Also

r, and xlxmx, called by ranova

Examples

data(life)
petitr(life)

malthusian parameter

Description

Calculates the intrinsic rate of increase by solving the Birch equation. Uses the Newton method.

Usage

r(tab, eps = eps, maxiter = 100)

Arguments

tab

a data.frame with three columns : x, the age, lx, the proportion of survivors at age x, mx, the offspring number per individual in the age class x

eps

Precision for the convergence of Newton method. Default is object eps transmitted by the calling function r. must be defined for a standalone use

maxiter

maximum number of iterations for the Newton's method. default = 100

Value

a single numeric value : r

Author(s)

Jean-Sebastien PIERRE

References

Lotka 1924, Birch 1948.

See Also

petitr,xlxmx,ranova

Examples

data (tblif)
r(tblif,eps=0.0000001)

Analysis of Variance on per capita growth rate pseudovalues

Description

Accepts as input a series (list) of individual life tables (see r,petitr,life1), calculates the Jackknife estimator of r (per capita growth rate) on each table, and achieves a one way analysis of variance on the set of pseudovalues corresponding to each table.

Usage

ranova(listab, levels = NULL)

Arguments

listab

list of life tables. must be of class list, and each table of class data.frame

levels

a character vector giving level names for each life table. If NULL, the levels are named l1,l2, etc..

Value

a data frame with two columns: the set of pseudovalues, and a factor named pop. Can be retrieved and used for more sophisticated factor organisation

Author(s)

Jean-Sebastien Pierre

References

Lotka 1924, Birch 1948, Wratten 1982

See Also

r, and xlxmx, called by petitr~

Examples

data(life1,life2,life3)
ranova(list(life1,life2,life3))

population life table

Description

a population life table with three columns, x, lx, mx (See below)

Usage

data(tblif)

Format

A data frame with 10 observations on the following 3 variables.

x

a numeric vector, age

lx

a numeric vector, Proportion of survivors at age x

mx

a numeric vector, mean number of offspring produced in the age class x

Details

x must represent equal age classes in ascending order

Source

Application of the function xlxmx on the data set life

Examples

data(tblif)
r(tblif, eps=10e-08)

builds an average life table from a set of individuals

Description

Calculates a life table with three columns, x, lx mx from the age specific birth data of a set of individuals. Called by petitr, but may be used as standalone function.

Usage

xlxmx(X, s)

Arguments

X

a data.frame. See petitr

s

Sex ratio expressed as the proportion of females in the population

Value

a data.frame with three columns, x (age), lx (survival at age x), mx (birth rate at age x)

Author(s)

Jean-Sebastien Pierre [email protected]

References

Lotka 1924, Birch 1948

See Also

r, and petitr, called by ranova

Examples

data(life)
tablif=xlxmx(life,s=1)