Description Usage Arguments Value Examples
This function groups variable based on its value. The variable is not sorted, so make sure to sort before running the function. Rows with the same value but not adjacent are not in the same group.
1 |
df |
a data frame object. |
var |
the variable in |
a numeric list of group numbers
1 2 3 | A<- rep(1:3, times = 2, each = 2)
A<- data.frame(A)
A$group<- seqgroup(A, var = "A")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.