Learn R Programming

bivarhr (version 0.1.5)

.get_pval: Extract p-value from RTransferEntropy result

Description

Helper to extract a p-value from a coefficient table returned by RTransferEntropy or similar packages. It searches for a column whose name matches "^p[._ -]?value$" (case-insensitive) and returns the first-row entry of that column.

Usage

.get_pval(obj)

Value

A numeric scalar with the extracted p-value, or NA_real_ if no suitable column is found or extraction fails.

Arguments

obj

An object for which coef(obj) returns a matrix containing a p-value column.