Skip to contents

Parses an input alpha value to be used in numeric summary calculations

Usage

checkSimAlpha(alpha = 95)

Arguments

alpha

Alpha value to be parsed

Value

A single numeric between .5 and 1

Details

The function first checks that there is only 1 input. If character, the alpha is parsed and converted to a single numeric. If alpha is greater than 1, it is assumed to be on the [1,100] scale, and will be scaled onto the [0,1] scale If alpha is less than 0.5, it is assumed to tbe on the [0,.5] scale (ie. .05 instead of .95) and converted to the [.5, 1] scale

Author

Mike K Smith mstoolkit@googlemail.com

Examples


  checkSimAlpha("95%")
#> [1] 0.95
  checkSimAlpha(95)
#> [1] 0.95
  checkSimAlpha(5)
#> [1] 0.95