Description Usage Arguments Value Examples
Permutation test
1 2 3 4 5 6 7 8 9 10 |
Y |
a numeric vector of size |
X |
a data frame of numeric or factor vector(s) of size |
Z |
a data frame of numeric or factor vector(s)
of size |
n_perm |
the number of permutations. Default is |
parallel |
a logical flag indicating whether parallel computation
should be enabled. Default is |
n_cpus |
an integer indicating the number of cores to be used when
|
space_y |
a logical flag indicating whether the y thresholds are spaced.
When |
number_y |
an integer value indicating the number of y thresholds (and therefore
the number of regressions) to perform the test. Default is |
A data frame with the following elements:
score
contains the test statistic for a given gene.
raw_pval
contains the raw p-values for a given gene computed from n_perm
permutations.
1 2 3 4 | if(interactive()){
X <- as.factor(rbinom(n=100, size = 1, prob = 0.5))
Y <- ((X==1)*rnorm(n = 50,0,1)) + ((X==0)*rnorm(n = 50,0.5,1))
res_perm <- test_perm(Y,data.frame(X=X),n_perm=10)}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.