splitgroups {PCAmixdata} | R Documentation |
splitgroups
Description
If the p variables of a data matrix of dimension (n,p) are separated into G groups, this functions splits this data matrix into G
datasets according the groups membership.
Usage
splitgroups(data, groups, name.groups)
Arguments
data |
the a data matrix into |
groups |
a vector of size |
name.groups |
a vector of size |
Value
data.groups |
a list of G data matrix: one matrix for each group. |
listvar.groups |
The list of the variables in each group. |
Examples
data(decathlon)
split <- splitgroups(decathlon,groups=c(rep(1,10),2,2,3),
name.groups=c("Epreuve","Classement","Competition"))
split$data.groups$Epreuve
[Package PCAmixdata version 3.1 Index]