Description Usage Arguments Examples
This function runs tContrast sampling in parallel
1 2 |
data |
compound activity data with individual compounds in rows and replicates in columns |
mu.prior |
location parameter for prior distribution of mu. Typically the average of all compound activity. |
var.prior |
spread parameter for prior distribution of mu. Typically the square standard error of the mean for all compounds. |
a |
alpha parameter for prior distribution of compound variance. See EstimateAB. |
b |
beta parameter for prior distribution of compound variance. See EstimateAB. |
null.post |
a MCMC sampling of a null posterior with column name mu. |
alternative |
a character string specifying the relationship to the null posterior, must be one of "two.sided", "greater", or "less". |
runjags.method |
method by which jags is run, default is set to 'simple' to avoid conflict with snow library |
rope |
Region of Practical Equivalence. This value specifies how close the sampled posterior needs to be to the null posterior to consider them equivalent, default value is 0. |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | set.seed(7)
compounds <- matrix(rnorm(20, seq(0, 100, 10), 3), nrow=10)
null.reference <- rnorm(32, 0, 3)
pooled <- c(null.reference, sapply(compounds, function(x) x))
mu.prior <- median(pooled)
var.prior <- var(null.reference)
nu.prior <- 1
a <- 30
b <- 3100
ROPE <- 15
null.post <- tSample(null.reference, mu.prior, var.prior, nu.prior, a, b)
posteriors <- tParallel(compounds, mu.prior, var.prior, nu.prior, a, b,
null.post, ROPE, alternative='greater')
rbindlist(posteriors)
compounds
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.