Description Usage Arguments Value Author(s) See Also Examples
Calculates means for each group
1 | groupMeans(variables, group, na.rm = FALSE)
|
variables |
matrix or data frame with explanatory variables (may contain missing values) |
group |
vector or factor with group memberships |
na.rm |
logical indicating whether missing values should be removed |
matrix of group means (with variables in the rows, and groups in the columns)
Gaston Sanchez
groupVars
, groupStds
,
groupMedians
, groupQuants
1 2 3 4 5 6 7 8 |
setosa versicolor virginica
Sepal.Length 5.006 5.936 6.588
Sepal.Width 3.428 2.770 2.974
Petal.Length 1.462 4.260 5.552
Petal.Width 0.246 1.326 2.026
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.