get_p_Gaussian {ISS} | R Documentation |
Calculate the p-value in Definition 19 of Müller et al. (2023).
get_p_Gaussian(X, y, x0, tau)
X |
a numeric matrix specifying the covariates. |
y |
a numeric vector with |
x0 |
a numeric vector specifying the point of interest, such that
|
tau |
a single numeric value specifying the threshold of interest. |
A single numeric value in (0, 1].
Müller MM, Reeve HWJ, Cannings TI, Samworth RJ (2023). “Isotonic subgroup selection.” arXiv preprint arXiv:2305.04852.
set.seed(123)
n <- 100
d <- 2
X <- matrix(runif(d * n), ncol = d)
eta <- function(x) sum(x)
y <- apply(X, MARGIN = 1, FUN = eta) + rnorm(n, sd = 1)
get_p_Gaussian(X, y, x0 = c(1, 1), tau = 1)
get_p_Gaussian(X, y, x0 = c(1, 1), tau = -1)