Description Usage Arguments Details Value See Also Examples
View source: R/ICP-variable_analysis.R
The model_analysis function takes an ICP object and a
significance level and outputs the accepted model at this level.
1 | model_analysis(x, level = 0.05, gof = 0.01)
|
x |
An ICP object |
level |
The significance level required for a model to be considered
invariant. The higher the significance |
gof |
If no set of variables (including the empty set) leads to a
p-value larger than the goodness-of-fit cutoff |
The function model_analysis takes an ICP object and a
significance level and outputs the accepted model at this level:
ICP for more details on the hypotheses
(H0,S).
The gof parameter protects against making statements when the model is
obviously not suitable for the data. If no model reaches the threshold
gof significance level, i.e. the p-values for
(H0,S) are all smaller then
gof, we report that there is no evidence for an invariant set.
This function is also used internally in the ICP function
itself if ICP is called with level specified.
model_analysis returns an object of class
"model_analysis" containing the following components:
gof |
goodness-of-fit cufoff. |
level |
significance level of hypothesis tests. |
accepted.model |
the accepted model. |
empty.message |
if the empty set is returned as |
call |
the matched call. |
The model_analysis function is also used internally in the
ICP function itself if ICP is called with
level specified.
variable_analysis is another function for summarizing
ICP objects.
1 2 3 4 5 6 7 | n <- 100
E <- sample(5L, n, replace = TRUE)
X <- data.frame(X1 = rnorm(n, E, 1), X2 = rnorm(n, 3, 1))
Y <- rnorm(n, X$X1, 1)
obj <- ICP(Y, X, E, fullAnalysis = TRUE)
model_analysis(obj, level = 0.05, gof = 0.15)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.