A faster pmax().

Arguments

x

A numeric vector.

a

A single numeric value.

Value

The parallel maximum of the input values. pmax0(x) is shorthand for pmaxC(x, 0), i.e. convert negative values in x to 0.

Note

This function will always be faster than pmax(x, a) when a is a single value, but can be slower than pmax.int(x, a) when x is short. Use this function when comparing a numeric vector with a single value.