label_vec2mat: Convert label vector to matrix
Description
Convert label vector to matrix
Usage
label_vec2mat(z, K = NULL, sparse = FALSE)
Value
A cluster assignment matrix that follows from the label vector z
Arguments
- z
a label vector
- K
number of labels in z
- sparse
whether the output should be sparse matrix