Pderiv: Derivative of the Prevalence Function

Description Usage Arguments Details Value Examples

View source: R/Pderiv.R

Description

The prevalence ratio is calculated as the number of individuals/elements carrying a specific trait by the number of individuals/elements in the sample. This function calculates the derivative of this term.

Usage

1
Pderiv(s, c)

Arguments

s

An integer specifying the number of individuals/elements in the sample.

c

An integer, specifying the number of cases, i. e. the number of individuals/elements carrying the trait of interest in the sample.

Details

The prevalence ratio is determined both by the number of indivduals/elements carrying the trait of interest and by the number of individuals/elements in the sample. The graph of a prevalence function with a fixed number of affected indivduals/elements and a variable sample size has both the x and the y axis as asymptotes. The derivative of the prevalence function yields the slope of a tangent line to this graph for a specific sample size. It has been hypothesised to serve as an indicator of the effect of sample size on the local prevalence ratio.

Value

The derivative of the prevalence function is returned as a rational number.

Examples

1
2
3
Pderiv(s=82, c=12)

Pderiv(s=43, c=12)

cuboideum/deadpop documentation built on Feb. 5, 2021, 11:21 p.m.