perm_cont: Permutation procedure when Z is continuous

Description Usage Arguments Value Examples

View source: R/perm_cont.R

Description

Permutation procedure when Z is continuous

Usage

1
perm_cont(Y, X, Z)

Arguments

Y

a numeric vector of size n containing the preprocessed expressions from n samples (or cells).

X

a numeric or factor vector of size n containing the variable to be tested (the condition to be tested).

Z

a numeric vector of size n containing the covariate. Multiple variables are not allowed.

Value

X_star a vector of permuted X.

Examples

1
2
3
4
5
if(interactive()){
X <- rbinom(n=100, size = 1, prob = 0.5)
Z <- rnorm(100,0,1)
Y <- ((X==1)*rnorm(n = 50,0,1)) + ((X==0)*rnorm(n = 50,0.5,1))
res <- perm_cont(Y,X,Z)}

ccdf documentation built on Sept. 24, 2021, 9:07 a.m.