pval2z: Convert p-values to Z-scores

View source: R/pval2z.R

pval2zR Documentation

Convert p-values to Z-scores

Description

Counvert two-sided test p-values to Z-scores using qnorm.

Usage

pval2z(pval, direction)

Arguments

pval

Vector of two-sided test p-values.

direction

Numeric or character vector of same length of p-value vector. Examples of numeric values are log fold-change, regression slope, or correlation coefficient. For character values, only "Up" and "Down" are allowed.

Details

P-values of zero are changed to half the lowest non-zero p-value and p-values of one are analogously changed, as p-values of zero or one would yield infinite z-scores.

Value

Vector of Z-scores.


jdreyf/jdcbioinfo documentation built on Feb. 12, 2025, 4:30 p.m.