Penalty of mixture weights
Computes the penalty Ω(\mathbf{W}) of the weight matrix (or vector) for a mixture model.
compute_mixture_penalty(weigh.matrix, type = c("entropy", "Lq", "lognorm", "MDL"), q = 2, row.average = TRUE, base = 2)
weigh.matrix |
N \times K weight matrix |
type |
type of penalty: |
q |
exponent for L_q norm. |
row.average |
logical; if |
base |
logarithm base for the |
WW <- matrix(c(rexp(10, 1/10), runif(10), 1/10), ncol = 3, byrow = FALSE) WW[1, 1] <- 0 WW <- normalize(WW) compute_mixture_penalty(WW, row.average = FALSE) compute_mixture_penalty(WW, row.average = TRUE) # default: average penalty
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.