test_veris_ratio: Test the ratio of Ea to Eb

View source: R/ci.R

test_veris_ratioR Documentation

Test the ratio of Ea to Eb

Description

Often we want to create quotes of the form "X is N times more/less likely than y in Z" This function provides a test for such quotes. It checks that the ratio is within the ci.level credible interval and that the credible interval does not include 1 (indicating that we lack the ci.level confidence in the direciton of the ratio)

Usage

test_veris_ratio(
  chunk,
  Ea,
  Eb,
  ratio,
  direction,
  ci.level = 0.05,
  reps = 1000,
  quietly = FALSE,
  visualize = FALSE
)

Arguments

chunk

getenumCI() output

Ea

Enumeration A. e.g. "action.Error"

Eb

Enumeration B. e.g. "action.Misuse"

ratio

The ratio of Ea to Eb to test as a number. Must be greater than 1.

direction

the direction to test ("greater" or "less")

ci.level

the confidence level to test against

reps

number of simulations to conduct

quietly

do not produce textual output

visualize

produce visual output

Value

a logical TRUE/FALSE to the hypothesis


vz-risk/verisr documentation built on Aug. 5, 2023, 4:34 a.m.