These functions calculate the contribution of covariate
or samples to the test statistic.
They are called by the function proprius
.
intern.sam(y, X, mu, phi) intern.cov(y, X, mu, phi)
y | response variable: numeric vector of length |
---|---|
X | covariate set: numeric matrix with |
mu | mean parameters: numeric vector of length |
phi | dispersion parameter: non-negative real number |
Both functions return a numeric vector.
A Rauschenberger, MA Jonker, MA van de Wiel, and RX Menezes (2016). "Testing for association between RNA-Seq and high-dimensional data", BMC Bioinformatics. 17:118. html pdf (open access)
JJ Goeman, SA van de Geer, F de Kort, and HC van Houwelingen (2004). "A global test for groups of genes: testing association with a clinical outcome", Bioinformatics. 20:93-99. html pdf (open access)
This is an internal
function. The user functions
of the R package globalSeq
are cursus
,
omnibus
, and proprius
.
# simulate high-dimensional data n <- 30 p <- 100 set.seed(1) y <- rnbinom(n,mu=10,size=1/0.25) X <- matrix(rnorm(n*p),nrow=n,ncol=p) # prepare arguments mu <- rep(mean(y),n) phi <- (var(y)-mean(y))/mean(y)^2 # decompose test statistic intern.sam(y,X,mu,phi)#> [1] -1.87251200 -0.04943005 -1.12090207 -2.31182733 22.76985777 0.31691196 #> [7] -2.90176706 -0.89580977 -0.68685844 0.65652399 -2.27981714 -2.23197510 #> [13] -2.52208409 -0.86333166 -1.96865273 -1.31557081 -1.68420108 -0.74995723 #> [19] -1.85360881 0.94576474 -1.21851805 -0.37637123 4.56087248 -0.96595528 #> [25] -1.91136954 -2.43329131 -2.05979016 -1.80528093 4.97110905 -2.33953196intern.cov(y,X,mu,phi)#> [1] 1.049060679 -0.234125443 -0.056202972 -0.620977194 -0.621153485 #> [6] -0.507660040 -0.087996554 -0.574546686 0.089796216 -0.232250236 #> [11] 0.444485058 -0.458648541 -0.674122002 -0.573100866 -0.736714508 #> [16] -0.162651383 -0.459080444 -0.325224225 -0.462686452 -0.177993029 #> [21] 2.935023636 -0.266500625 0.535749676 -0.510098158 -0.445433079 #> [26] -0.526123009 -0.682420182 -0.382895069 -0.459175256 -0.562329107 #> [31] -0.769843213 0.270279508 -0.343176618 -0.657637213 0.077427625 #> [36] 1.351436772 0.038519033 0.648698075 -0.650411033 0.449301792 #> [41] -0.582571236 5.620015607 -0.028518614 1.035735328 -0.114736542 #> [46] 0.396428771 -0.650584776 1.867054334 -0.558053101 0.272330236 #> [51] -0.502019314 -0.114363648 -0.535541503 -0.341173943 -0.761795998 #> [56] -0.912355334 0.279543189 -0.303971902 0.004927843 -0.607805686 #> [61] -0.026328400 -0.591493484 -0.347746014 1.019483777 0.084170864 #> [66] -0.653007136 0.278079299 0.122429823 -0.360277129 2.033642503 #> [71] -0.368942122 -0.616278328 -0.361477180 -0.609342441 -0.378778312 #> [76] 0.581585160 -0.235773763 -0.429562361 -0.183995677 -0.622591967 #> [81] -0.181565332 0.399134981 0.651835794 0.452413312 -0.009072119 #> [86] 0.026924560 -0.375958591 1.334497098 0.568657921 -0.311397128 #> [91] -0.784913113 -0.669940323 -0.468648577 -0.157820350 -0.234847412 #> [96] -0.516427926 -0.652375051 -0.594495283 1.432470280 -0.570788858