Description Usage Arguments Value Examples
This function describes the structure of sub-regression given by an adjacency matrix. It computes the associated regression coefficients and R-squared for each sub-regression.
1 2 3 |
Z |
binary adjacency matrix of the structure (size p) |
B |
is the complete structure (Z with sub-regression coefficients instead of 1 and an additional first line for the intercepts) |
crit |
define the criterion to use: c("none","R2","F","sigmaX") |
varnames |
the names of the variables (size p) |
output |
indicates the content of the output: c("index","names","all") |
X |
is a data frame or matrix containing the dataset |
order |
define the order used (0: none, -1: decreasing, 1: growing) for printing |
a list containing the sub-regressions details. Each item of the list represents a subregression. First element is the R-square.Second element is the variable that is regressed by others. Then comes the list of the explicative variables in the subgression and the associated coefficients (in the first column).
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
data<-mtcars
#we first search a sub-regression structure
res=structureFinder(X = data,nbini = 30,verbose=0)
#then we can try to interpret it
readZ(Z = res$Z_opt,crit = "R2",output = "all",X = data)
#each component is a sub-regression
#First line : The adjusted R-squared is given
#Second line : the name of the covariate that is regressed by others
#other lines : Coefficients of sub-regression and name of the associated covariate
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.