xy_outcomes2factor: Convert two numeric ternary outcomes into a factor
Description
Convert two numeric ternary outcomes into a factor
Usage
xy_outcomes2factor(x, y)
xy_thresholds2factor(x, y, x_threshold = 0, y_threshold = 0)
Arguments
x, y
numeric vectors of -1, 0, and +1 values, indicating down
regulation, uncertain response or upregulation, or numeric vectors that can be
converted into such values using a pair of thresholds.
x_threshold, y_threshold
numeric vector Ranges enclosing the values to be considered
uncertain for each of the two vectors..
Details
This function converts the numerically encoded values into a factor
with the four levels "xy", "x", "y" and "none".
The factor created can be used for faceting or can be mapped to aesthetics.