Select the regularization coefficient for three-way clustering. The clustering size is assumed to be known. The function searches over a range of regularization sizes and outputs the one that minimizes the BIC.
chooseLambda(x, k, r, l, lambda = NULL, method = "L0")a three-dimensional array
an positive integer, the numbers of clusters at mode 1
an positive integer, the numbers of clusters at mode 2
an positive integer, the numbers of clusters at mode 3
a vector of possible lambda, eg: lambda = c(0,50,100,200)
two options: "L0", "L1". "L0" indicates L0 penalty, and "L1" indicates Lasso penalty
a list
lambda the lambda with lowest BIC
BIC the BIC for each lambda in the given range
nonzeromus the number of clusters with non-zero means