powered by
x
indices
Generic method for obtaining the marginal distribution of a distribution object x over components indices.
marginal(x, indices)
A distribution object for the marginal over indices.
The distribution object.
The indices of the marginal distribution to obtain.
x <- mvn(c(0, 0), diag(2)) m <- marginal(x, 1) # marginal over first component mean(m) # 0
Run the code above in your browser using DataLab