.flatten_group_to_df | R Documentation |
This function takes a matrix with an attribute "gr" representing group sizes and flattens it into a data frame, adding a 'gr' column to indicate the group each row belongs to.
.flatten_group_to_df(x)
x |
A matrix containing the data to be flattened. The matrix should have an attribute "gr" that contains the size for each group. |
A data frame containing the flattened data with an additional 'gr' column indicating the group each row belongs to.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.