sumgcols | R Documentation |
Groups a matrix by columns, by summing blocks of columns of size n each. Matrix columns should be multiple of n.
sumgcols(df, n, col_names = NULL)
df |
A matrix with named rows and columns. |
n |
Integer, specifying the size of each group. |
col_names |
String vector of length n, with names to assign to the resulting columns. |
A matrix where each column is the sum of groups of n columns of the original matrix.
wio <- make_wio("wiodtest", quiet = TRUE)
sumgcols(wio$Yfd, wio$dims$FD, wio$names$g_names)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.