Learn R Programming

lazyWeave (version 2.2.0)

pvalue.QHS: Format p-values

Description

Prepares p-values for printing according to the Alpha-Beta team standards.

Usage

pvalue.QHS(value)

Arguments

value
A single number. 0 value < 1.

Details

Cleveland Clinic Foundation's Alpha-Beta team uses the following format for p-values when presenting results to researchers: ll{ values greater than 0.99 are reported as '> 0.99' values between 0.99 and 0.10 are reported with two significant digits values between 0.001 and 0.10 are reported with three significant digits values less than 0.001 are reported as '< 0.001'. }

Examples

Run this code
pvalue.QHS(1.0)
  pvalue.QHS(runif(1,0,1))

  ## The dataset 'women' is in the package 'datasets'
  pvalue.QHS( t.test(women$height)$p.value )

Run the code above in your browser using DataLab