This function returns a DISTRIBUTION
with a new dimension
created by row sum of the dimensions of the distribution.
Arguments
- p_distribution
an object of class
DISTRIBUTION
- p_totalname
the name of the new dimension
Examples
d1 <- new_DIRICHLET(c(0.2,0.5,0.3))
d2 <- add_total(d1)