Description Usage Arguments Author(s) Examples
The function splits an ecogen object into the groups defined in the slot S. If asList is TRUE, a list with the objects is created , that can be assigned to a name with regular rules, using the operator "<-". Otherwise, the function creates in the workspace an ecogen object for each group with the following nomenclature: <name of ecogen object>.<name of the group>.
1 2 3 4 5 6 7 8 |
eco |
Object of class "ecogen". |
hier |
The name of the S slot column with labels assigning individuals to groups. |
name |
Name used for the output objects. Default is the name of the input,followed by a suffix (see Description). |
overwrite |
Overwrite files with the same name of the output if already present in workspace when asList = FALSE? Default FALSE. |
missing |
Missing data argument This can take three values ("0", "NA" or "MEAN"),
as described in |
asList |
Return a list with the objects instead of creating objects in workspace? Default = TRUE |
Leandro Roser learoser@gmail.com
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | ## Not run:
data(eco3)
eco3
# list of objects
x <- eco.split(eco3, "structure", asList = TRUE)
# rebinding
eco.bind <- eco.rbind(x)
# note that different subsets can also be created
S1.3 <- eco.rbind(x[[1]], x[[3]])
# split and create objects with prefix "eco3"
eco.split(eco3,"structure", asList = FALSE)
# split and create objects with prefix "newObjects"
eco.split(eco3,"structure", "newObjects", asList = FALSE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.