showModel {CoCoRaw} | R Documentation |
Print on standard output the model. The model can also be given a longer description with adjacency matrix and expression for estimates.
showModel(model = FALSE, a = FALSE, b = FALSE, describe.model = FALSE, data = NULL, object = .object.of.model(model, data = data, ...), ...)
model |
Numeric, model object, text string, or logical.
A numeric should give a valid model number in the object ,
see makeCurrent about the model list.
The argument can also be a CoCo model object, see
makeModel about creating model objects.
The text strings "base" , "current" , or "last"
refers to the three models.
The text strings "interval" will show the interval
given by the arguments a and b .
The default value "current" for the CURRENT model
can also be given as the logical FALSE (or NULL).
model can also be a vector or list with the above,
but not recursive.
model can not be a character string with a generating class.
|
a |
Numeric, a is the first model of the interval. |
b |
Numeric, b is the last model of the interval. |
describe.model |
Logical, if describe.model is TRUE
the the longer description is given. |
data |
See exportCoCo . |
object |
See exportCoCo . |
... |
Additional arguments to generate the CoCo object
from the data argument. See propertyModel . |
TRUE
Jens Henrik Badsberg
Badsberg, J.H.: A guide to CoCo, JSS, 2001 ( http://www.jstatsoft.org/v06/i04/ ) and Badsberg, J.H.: Xlisp+CoCo, Aalborg University, 1996.
enterModel
and makeCurrent
.
library(CoCo); data(Byssinosis38); CoCoObject <- makeCoCo(); enterTable(Byssinosis38, object = CoCoObject); # Generate some models: enterModel("*", object = CoCoObject); backward(recursive = TRUE, headlong = TRUE, coherent = TRUE, follow = TRUE, object = CoCoObject); backwardResult <- returnModelNumber("last", object = CoCoObject); enterModel(".;", object = CoCoObject); forward(recursive = TRUE, headlong = TRUE, coherent = TRUE, object = CoCoObject); makeCurrent(backwardResult, object = CoCoObject); # Show the models: showModel("all", object = CoCoObject); showModel("last", object = CoCoObject); showModel("base", object = CoCoObject); showModel("current", object = CoCoObject); showModel("number", 3, object = CoCoObject); # showModel(FALSE, object = CoCoObject); # showModel(TRUE, object = CoCoObject); # showModel(NULL, object = CoCoObject); # showModel(c(1, 2, c(7)), object = CoCoObject); # showModel("list", list(1, 2), object = CoCoObject); # showModel(c("current", 7, 9, "last"), object = CoCoObject); # showModel(c("current", "base", "last"), object = CoCoObject); # showModel("list", list("current", 2), object = CoCoObject); # Show the model "backwardResult" down to 1: while(makeCurrent("previous", object = CoCoObject)) showModel(object = CoCoObject); # Show the model 10 to 15 3 times: showModel(10:15, object = CoCoObject); showModel("interval", 10, 15, object = CoCoObject); makeCurrent(10, object = CoCoObject) while(returnModelNumber("current", object = CoCoObject) < 15) { makeCurrent("next", object = CoCoObject); showModel(object = CoCoObject); } makeCurrent(backwardResult, object = CoCoObject); showModel(6, describe.model = TRUE, object = CoCoObject); showModel("current", describe.model = TRUE, object = CoCoObject); showModel(1, describe.model = TRUE, object = CoCoObject); # "base" and "last" gives shorter description: showModel("base", describe.model = TRUE, object = CoCoObject); showModel("last", describe.model = TRUE, object = CoCoObject); endCoCo(object = CoCoObject);