applyGenerateProbs: Generate probabilities missing from RDBES Data

View source: R/applyGenerateProbs.R

applyGenerateProbsR Documentation

Generate probabilities missing from RDBES Data

Description

Wrapper to generate probabilities. The wrapper calls runChecksOnSelectionAndProbs which main tests need to be passed before probabilities can be calculated. The it calls generateProbs for each sample in each sampling level of the hierarchy.

Usage

applyGenerateProbs(
  x,
  probType,
  overwrite,
  runInitialProbChecks = TRUE,
  verbose = FALSE,
  strict = TRUE
)

Arguments

x
  • RDBES data object

probType
  • string. Can be set to "selection" (only selection probabilities are calculated), "inclusion" (only inclusion probabilities are calculated) or "both" (both types of probabilities are calculated)

overwrite
  • if TRUE will overwrite probabilities already existing for SRSWR and SRSWOR

runInitialProbChecks
  • if TRUE runs runChecksOnSelectionAndProbs

verbose

(Optional) Set to TRUE if you want informative text printed out, or FALSE if you don't. The default is FALSE.

strict

(Optional) This function validates its input data - should the validation be strict? The default is TRUE.

Value

a list of all the RDBES data tables with probabilites calculated

See Also

runChecksOnSelectionAndProbs generateProbs

Examples

# To be added

ices-tools-dev/icesRDBES documentation built on April 17, 2025, 1:58 p.m.