ifneg: ifneg function

View source: R/format.R

ifnegR Documentation

ifneg function

Description

checks if the transposed values of a matrix are negative and maps different values to it if they are or are not

Usage

ifneg(mat, t = 1, f = 3)

Arguments

mat

matrix to be used (should not already be transposed as the matrix does this-if the martix is in the orientation needed for a barplot without transposing you may need to transpose it when feeding into this function)

t

the value to map the negative values to. defaults to 1

f

the value to map the positive values to. defaults to 3

Examples

ifneg_function()

clmacleod/highlandr documentation built on Feb. 18, 2025, 1:31 p.m.