Description Usage Arguments Details Value
View source: R/BuildModelData.R
BuildModelData
is an internal function that constructs a data.table
from groups, x, and y to be used in regression model.
1 | BuildModelData(comparison, x, y = NULL, groups = NULL, by = NULL, xName, yName)
|
x |
A matrix or list of matrices containing values for model. |
y |
A matrix containing values to be used on left-hand side of model (e.g. dependent variable). At least one of y or groups must be provided. |
groups |
A data.frame containing sample group data. At least one of y or groups must be provided. Column one of groups data.frame must contain sample names that correspond to column names of x and y. |
by |
Character vector specifying column names in groups that will be used to split data if stratified analysis desired. Ignored if groups not provided. |
xName |
Names of matrices provided in x. If x is a list with named elements, defaults to list names. Else, defaults to x1, x2, ..., xn where n is the number of matrices provided in x. |
yName |
Name of matrix or name of column in groups to be used on left-hand of model. (see formula details for default values) |
comparisons |
Matrix containing rownames or numbers from each dataset for all desired comparisons. If not provided, comparisons matrix will be build (see details for defaults). |
This function binds together desired rows in x and y with groups object to create model data.
A data.table with all data to be used in model.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.