pvalnum: Make sure _p_-values are numeric

View source: R/util.R

pvalnumR Documentation

Make sure p-values are numeric

Description

Make sure p-values are numeric. Non-numeric values (e.g., "<0.001") are converted to zero.

Usage

pvalnum(pvals)

Arguments

pvals

Vector of p-values which might not be fully numeric.

Value

A vector of fully numeric p-values.

Examples

micompr:::pvalnum(c("0.06", "0.9", "<0.0001", "0.3"))
# [1] 0.06 0.90 0.00 0.30


micompr documentation built on June 29, 2025, 1:08 a.m.