contrast {lestat} | R Documentation |
Computing the distribution of a Contrast
Description
For some distributions, like the multivariate Normal-ExpGamma and the multivariate Normal-Gamma, a new distribution is constructed from a linear combination of all but the last variables, and the last variable.
Usage
contrast(object, v)
Arguments
object |
A multivariate Normal-ExpGamma distribution or multivariate Normal-Gamma distribution. |
v |
A vector specifying the linear combination. |
Value
A Normal-ExpGamma distribution or a Normal-Gamma distribution, depending on the input.
Author(s)
Petter Mostad <mostad@chalmers.se>
Examples
data1 <- simulate(normal(13, log(0.4)), 3)
data2 <- simulate(normal(14, log(0.4)), 5)
data3 <- simulate(normal(12, log(0.4)), 6)
dist <- linearmodel(c(data1, data2, data3), designManyGroups(c(3,5,6)))
diff <- contrast(dist, c(0, 1, -1))
credibilityinterval(marginal(diff, 1))
[Package lestat version 1.9 Index]