createSimModel(formulas,
tMissingRate = c(0),
markerInfo = NULL,
ascertainment = NULL,
defaultError = '',
assumeExogCovariate = TRUE)
strumSimModel.strumSimModel object which will be an
input parameter for simulateStrumData function.
The formulas argument is given as a charactor string of several expressions that
defines the relationship among the variables. Blank lines and comments (line start
with #) can be included between formulas.
Note that the coefficients of the right hand side variables of the measurement
equations are fixed with the value given in the formulas.
Three different equations are allowed in the formulas syntax:
p, e, a or c
is not included in the model formulas, then, by default, the value of
defaultError is included in the model. For quantitative traits, the
e term should always be present. Therefore, the program automatically
include e term even if no error terms are specified either in
formulas nor in defaultError.
Note that "a" (additive), "p" (polygenic), "c" (common environmental) and
"e"(independent environmental) are reserved variable names to specify a type of
variance component, so that may not be used as input arguments.
The return value of ascertainment function is composed of two components for
each pedigree, allowing either one of components or both components to be returned as a list.
The first component is a TRUE/FALSE value indicating the ascertainment status of the pedigree.
The second component is a vector of TRUE/FALSE stating the proband status of each
member of the pedigree. Here are some examples:
strumSimModel , strumMarker # Create a strumSimModel.
# - simForm is a formulas string.
# - snpStrumMarker is an object of strumMarker class.
# - aFunction is an ascertainment function definition.
#------------------------------------------------------
mySimModel = createSimModel(
formulas = simForm,
markerInfo = snpStrumMarker,
ascertainment = aFunction
)Run the code above in your browser using DataLab