Learn R Programming

SurrogateOutcome (version 1.1)

new.q: Helper function

Description

Helper function; should not be called directly by user. This function differs from the quantile function in that it returns an NA when there are NAs in the supplied vector, rather than causing an error.

Usage

new.q(x, p)

Arguments

x

vector of numeric values

p

sample quantile that is desired

Value

returns either NA or the desired sample quantile