When the information about a model is available, it reconstructs it and returns a valid model object.
## S3 method for class 'slseFit'as.model(x,...)## S3 method for class 'cslseFit'as.model(x,...)## S3 method for class 'cslse'as.model(x,...)
Arguments
x: An object containing the model to extract.
...: Other arguments to pass to other methods. Currently not used.
Returns
The method returns an object of class slseModel or cslseModel.
Examples
data(simDat3)mod <- cslseModel(Y ~ Z |~ X1 * X2, data = simDat3)fit <- estSLSE(mod)## Extract the model from a cslseModel objectas.model(fit)## Extract the model from a cslse objectcs <- causalSLSE(mod)as.model(cs)