computeAlpha | R Documentation |
For a vector of herd sizes the herd-based alpha-errors (= 1-herd sensitivity) are computed for either limited or individual sampling; see Ziller et al.
computeAlpha(nAnimalVec, method, sampleSizeLtd, herdSensitivity, intraHerdPrevalence, diagSensitivity, diagSpecificity = 1)
nAnimalVec |
Integer vector. Stock sizes of the herds. |
method |
Character string. |
sampleSizeLtd |
Integer. Required only if |
herdSensitivity |
Numeric between 0 and 1. Required only if |
intraHerdPrevalence |
Numeric between 0 and 1. Intra-herd prevalence. The number of diseased
animals per herd is computed as
|
diagSensitivity |
Numeric between 0 and 1. Sensitivity (= probability of a testpositive result, given the tested individual is diseased) of the diagnostic test. |
diagSpecificity |
Numeric between 0 and 1. Specificity (= probability of a testnegative result, given the tested individual is not diseased) of the diagnostic test. The default value is 1, i.e., perfect specificity, and is recommended. |
Returns a vector containing the herd-based alpha-errors, where each
entry in the vector corresponds to an entry in the input argument
nAnimalVec
.
Ian Kopacka <ian.kopacka@ages.at>
M. Ziller, T. Selhorst, J. Teuffert, M. Kramer and H. Schlueter, "Analysis of sampling strategies to substantiate freedom from disease in large areas", Prev. Vet. Med. 52 (2002), pp. 333-343.
Is used in the method sample
for classes IndSampling
and LtdSampling
.
data(sheepData) ## Compute the herd sensitivities usinh limited sampling: alphaVec <- computeAlpha(nAnimalVec = sheepData$nSheep, method = "limited", sampleSizeLtd = 7, intraHerdPrevalence = 0.2, diagSensitivity = 0.9)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.