Generate vector of selection or inclusion probabilities
generateProbs(x, probType)
RDBES data object
"selection" or "inclusion" for selection and inclusion probabilities respectively
A vector or probabilities
When the selection method is SRSWR selection probabilities are calculated as \(1 / N\) and inclusion probabilities as \(1 - (1 - 1 / N)^n\). When the selection method is SRSWOR selection probabilities are not currently implemented. Inclusion probabilities are calculated as \(n/N\). When the selection method is CENSUS both types of probabilities are set to 1. Probabilities for selection methods UPSWR and UPSWOR are not calculated (they need to be supplied by the user). The same happens with regards to non-probabilistic methods
if (FALSE) {
generateProbs(x = Pckg_SDAResources_agstrat_H1[["VS"]], probType = ("inclusion"))
# population size
a<-generateProbs(x = Pckg_SDAResources_agstrat_H1[["VS"]], probType = ("inclusion"))
sum(1/a$VSincProb)
# returns error
generateProbs(x = Pckg_SDAResources_agstrat_H1[["VS"]], probType = ("selection"))
}